home *** CD-ROM | disk | FTP | other *** search
/ MacWorld 1999 November / Macworld (1999-11).dmg / Updaters / WhiteCap 3.0.4 / WhiteCap Source.sit / WhiteCap Source / Common / General Tools / Headers / UtilStr.h < prev    next >
MacBinary  |  1999-07-13  |  12.1 KB  |  [TEXT/CWIE]

open in: MacOS 8.1     |     Win98     |     DOS

browse contents    |     view JSON data     |     view as text


This file was processed as: MacBinary (archive/macBinary).

ConfidenceProgramDetectionMatch TypeSupport
10% dexvert MacBinary (archive/macBinary) fallback Supported
1% dexvert Text File (text/txt) fallback Supported
100% file MacBinary II, inited, Tue Jul 13 21:53:55 1999, modified Tue Jul 13 21:53:55 1999, creator 'CWIE', type ASCII, 11685 bytes "UtilStr.h" , at 0x2e25 410 bytes resource default (weak)
99% file data default
74% TrID Macintosh plain text (MacBinary) default
25% TrID MacBinary 2 default (weak)
100% siegfried fmt/1762 MacBinary (II) default
100% lsar MacBinary default


id metadata
keyvalue
macFileType[TEXT]
macFileCreator[CWIE]



hex view
+--------+-------------------------+-------------------------+--------+--------+
|00000000| 00 09 55 74 69 6c 53 74 | 72 2e 68 00 00 00 00 00 |..UtilSt|r.h.....|
|00000010| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000020| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000030| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00000040| 00 54 45 58 54 43 57 49 | 45 01 00 00 00 00 00 00 |.TEXTCWI|E.......|
|00000050| 00 00 00 00 00 2d a5 00 | 00 01 9a b3 b1 9e 33 b3 |.....-..|......3.|
|00000060| b1 9e 33 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |..3.....|........|
|00000070| 00 00 00 00 00 00 00 00 | 00 00 81 81 4e 3e 00 00 |........|....N>..|
|00000080| 23 70 72 61 67 6d 61 20 | 6f 6e 63 65 0d 0d 23 69 |#pragma |once..#i|
|00000090| 66 6e 64 65 66 20 5f 43 | 55 54 49 4c 53 54 52 5f |fndef _C|UTILSTR_|
|000000a0| 0d 23 64 65 66 69 6e 65 | 20 5f 43 55 54 49 4c 53 |.#define| _CUTILS|
|000000b0| 54 52 5f 0d 0d 0d 23 69 | 66 6e 64 65 66 20 4e 55 |TR_...#i|fndef NU|
|000000c0| 4c 4c 0d 23 64 65 66 69 | 6e 65 20 4e 55 4c 4c 20 |LL.#defi|ne NULL |
|000000d0| 30 4c 0d 23 65 6e 64 69 | 66 0d 0d 23 69 6e 63 6c |0L.#endi|f..#incl|
|000000e0| 75 64 65 20 22 48 61 73 | 68 61 62 6c 65 2e 68 22 |ude "Has|hable.h"|
|000000f0| 0d 0d 0d 63 6c 61 73 73 | 20 43 45 67 49 53 74 72 |...class| CEgIStr|
|00000100| 65 61 6d 3b 0d 63 6c 61 | 73 73 20 43 45 67 4f 53 |eam;.cla|ss CEgOS|
|00000110| 74 72 65 61 6d 3b 0d 0d | 2f 2f 09 54 68 69 73 20 |tream;..|//.This |
|00000120| 69 73 20 76 65 72 73 69 | 74 69 6c 65 20 73 74 72 |is versi|tile str|
|00000130| 69 6e 67 20 63 6c 61 73 | 73 2c 20 6f 70 74 69 6d |ing clas|s, optim|
|00000140| 69 7a 65 64 20 66 6f 72 | 20 61 6c 6c 20 73 74 72 |ized for| all str|
|00000150| 69 6e 67 20 73 69 7a 65 | 73 0d 63 6c 61 73 73 20 |ing size|s.class |
|00000160| 55 74 69 6c 53 74 72 20 | 3a 20 70 75 62 6c 69 63 |UtilStr |: public|
|00000170| 20 48 61 73 68 61 62 6c | 65 20 7b 0d 0d 0d 09 70 | Hashabl|e {....p|
|00000180| 75 62 6c 69 63 3a 09 09 | 09 09 09 09 0d 09 09 09 |ublic:..|........|
|00000190| 09 09 09 09 09 09 55 74 | 69 6c 53 74 72 28 29 3b |......Ut|ilStr();|
|000001a0| 0d 09 09 09 09 09 09 09 | 09 09 55 74 69 6c 53 74 |........|..UtilSt|
|000001b0| 72 28 20 63 6f 6e 73 74 | 20 63 68 61 72 2a 20 69 |r( const| char* i|
|000001c0| 6e 43 53 74 72 20 29 3b | 0d 09 09 09 09 09 09 09 |nCStr );|........|
|000001d0| 09 09 55 74 69 6c 53 74 | 72 28 20 63 6f 6e 73 74 |..UtilSt|r( const|
|000001e0| 20 75 6e 73 69 67 6e 65 | 64 20 63 68 61 72 2a 20 | unsigne|d char* |
|000001f0| 69 6e 53 74 72 50 74 72 | 20 29 3b 0d 09 09 09 09 |inStrPtr| );.....|
|00000200| 09 09 09 09 09 55 74 69 | 6c 53 74 72 28 20 63 6f |.....Uti|lStr( co|
|00000210| 6e 73 74 20 55 74 69 6c | 53 74 72 26 20 69 6e 53 |nst Util|Str& inS|
|00000220| 74 72 20 29 3b 0d 09 09 | 09 09 09 09 09 09 09 55 |tr );...|.......U|
|00000230| 74 69 6c 53 74 72 28 20 | 63 6f 6e 73 74 20 55 74 |tilStr( |const Ut|
|00000240| 69 6c 53 74 72 2a 20 69 | 6e 53 74 72 20 29 3b 0d |ilStr* i|nStr );.|
|00000250| 09 09 09 09 09 09 09 09 | 09 55 74 69 6c 53 74 72 |........|.UtilStr|
|00000260| 28 20 6c 6f 6e 67 20 69 | 6e 4e 75 6d 20 29 3b 0d |( long i|nNum );.|
|00000270| 09 09 09 09 09 09 09 09 | 09 55 74 69 6c 53 74 72 |........|.UtilStr|
|00000280| 28 20 63 6f 6e 73 74 20 | 76 6f 69 64 2a 20 69 6e |( const |void* in|
|00000290| 50 74 72 2c 20 6c 6f 6e | 67 20 6e 75 6d 42 79 74 |Ptr, lon|g numByt|
|000002a0| 65 73 20 29 3b 0d 09 09 | 76 69 72 74 75 61 6c 09 |es );...|virtual.|
|000002b0| 09 09 09 09 09 7e 55 74 | 69 6c 53 74 72 28 29 3b |.....~Ut|ilStr();|
|000002c0| 0d 09 09 09 09 09 09 09 | 09 0d 09 09 2f 2f 09 2a |........|....//.*|
|000002d0| 2a 2a 20 41 73 73 69 67 | 6e 20 2a 2a 2a 0d 09 09 |** Assig|n ***...|
|000002e0| 2f 2f 09 50 6f 73 74 3a | 09 54 68 69 73 20 55 74 |//.Post:|.This Ut|
|000002f0| 69 6c 53 74 72 20 65 6d | 70 74 69 65 73 20 69 74 |ilStr em|pties it|
|00000300| 73 65 6c 66 20 61 6e 64 | 20 61 70 70 65 6e 64 73 |self and| appends|
|00000310| 20 74 68 65 20 61 72 67 | 75 6d 65 6e 74 20 28 69 | the arg|ument (i|
|00000320| 65 20 69 74 20 63 6f 70 | 69 65 73 20 74 68 65 20 |e it cop|ies the |
|00000330| 61 72 67 75 6d 65 6e 74 | 29 0d 09 09 69 6e 6c 69 |argument|)...inli|
|00000340| 6e 65 20 76 6f 69 64 09 | 09 09 09 09 41 73 73 69 |ne void.|....Assi|
|00000350| 67 6e 28 20 63 6f 6e 73 | 74 20 63 68 61 72 2a 20 |gn( cons|t char* |
|00000360| 69 6e 43 53 74 72 20 29 | 09 09 09 09 09 09 09 09 |inCStr )|........|
|00000370| 7b 20 6d 53 74 72 4c 65 | 6e 20 3d 20 30 3b 20 41 |{ mStrLe|n = 0; A|
|00000380| 70 70 65 6e 64 28 20 69 | 6e 43 53 74 72 20 29 3b |ppend( i|nCStr );|
|00000390| 09 09 09 09 7d 0d 09 09 | 76 6f 69 64 09 09 09 09 |....}...|void....|
|000003a0| 09 09 41 73 73 69 67 6e | 28 20 63 6f 6e 73 74 20 |..Assign|( const |
|000003b0| 75 6e 73 69 67 6e 65 64 | 20 63 68 61 72 2a 20 69 |unsigned| char* i|
|000003c0| 6e 53 74 72 50 74 72 20 | 29 3b 0d 09 09 76 6f 69 |nStrPtr |);...voi|
|000003d0| 64 09 09 09 09 09 09 41 | 73 73 69 67 6e 28 20 63 |d......A|ssign( c|
|000003e0| 6f 6e 73 74 20 55 74 69 | 6c 53 74 72 2a 20 69 6e |onst Uti|lStr* in|
|000003f0| 53 74 72 20 29 3b 0d 09 | 09 76 6f 69 64 09 09 09 |Str );..|.void...|
|00000400| 09 09 09 41 73 73 69 67 | 6e 28 20 63 6f 6e 73 74 |...Assig|n( const|
|00000410| 20 55 74 69 6c 53 74 72 | 26 20 69 6e 53 74 72 20 | UtilStr|& inStr |
|00000420| 29 3b 0d 09 09 76 6f 69 | 64 09 09 09 09 09 09 41 |);...voi|d......A|
|00000430| 73 73 69 67 6e 28 20 6c | 6f 6e 67 20 69 6e 4e 75 |ssign( l|ong inNu|
|00000440| 6d 20 29 3b 0d 09 09 76 | 6f 69 64 09 09 09 09 09 |m );...v|oid.....|
|00000450| 09 41 73 73 69 67 6e 28 | 20 63 68 61 72 20 69 6e |.Assign(| char in|
|00000460| 43 68 61 72 20 29 3b 0d | 09 09 76 6f 69 64 09 09 |Char );.|..void..|
|00000470| 09 09 09 09 41 73 73 69 | 67 6e 28 20 63 6f 6e 73 |....Assi|gn( cons|
|00000480| 74 20 76 6f 69 64 2a 20 | 69 6e 50 74 72 2c 20 6c |t void* |inPtr, l|
|00000490| 6f 6e 67 20 6e 75 6d 42 | 79 74 65 73 20 29 3b 0d |ong numB|ytes );.|
|000004a0| 09 09 76 6f 69 64 09 09 | 09 09 09 09 41 73 73 69 |..void..|....Assi|
|000004b0| 67 6e 28 20 43 45 67 49 | 53 74 72 65 61 6d 26 20 |gn( CEgI|Stream& |
|000004c0| 69 6e 53 74 72 65 61 6d | 2c 20 6c 6f 6e 67 20 6e |inStream|, long n|
|000004d0| 75 6d 42 79 74 65 73 20 | 29 3b 0d 09 09 0d 09 09 |umBytes |);......|
|000004e0| 2f 2f 20 20 2a 2a 2a 20 | 41 70 70 65 6e 64 20 2a |// *** |Append *|
|000004f0| 2a 2a 0d 09 09 2f 2f 09 | 50 6f 73 74 3a 09 54 68 |**...//.|Post:.Th|
|00000500| 65 20 61 72 67 75 6d 65 | 6e 74 20 69 73 20 61 70 |e argume|nt is ap|
|00000510| 70 65 6e 64 65 64 20 74 | 6f 20 74 68 69 73 20 73 |pended t|o this s|
|00000520| 74 72 69 6e 67 0d 09 09 | 76 6f 69 64 09 09 09 09 |tring...|void....|
|00000530| 09 09 41 70 70 65 6e 64 | 28 20 63 6f 6e 73 74 20 |..Append|( const |
|00000540| 63 68 61 72 2a 20 69 6e | 43 53 74 72 20 29 3b 0d |char* in|CStr );.|
|00000550| 09 09 69 6e 6c 69 6e 65 | 20 76 6f 69 64 09 09 09 |..inline| void...|
|00000560| 09 09 41 70 70 65 6e 64 | 28 20 63 6f 6e 73 74 20 |..Append|( const |
|00000570| 75 6e 73 69 67 6e 65 64 | 20 63 68 61 72 2a 20 69 |unsigned| char* i|
|00000580| 6e 53 74 72 50 74 72 20 | 29 3b 0d 09 09 69 6e 6c |nStrPtr |);...inl|
|00000590| 69 6e 65 20 76 6f 69 64 | 09 09 09 09 09 41 70 70 |ine void|.....App|
|000005a0| 65 6e 64 28 20 63 68 61 | 72 20 69 6e 43 68 61 72 |end( cha|r inChar|
|000005b0| 20 29 09 09 09 09 09 09 | 09 09 09 09 7b 20 41 70 | )......|....{ Ap|
|000005c0| 70 65 6e 64 28 20 26 69 | 6e 43 68 61 72 2c 20 31 |pend( &i|nChar, 1|
|000005d0| 20 29 3b 09 09 09 09 09 | 09 09 7d 0d 09 09 76 6f | );.....|..}...vo|
|000005e0| 69 64 09 09 09 09 09 09 | 41 70 70 65 6e 64 28 20 |id......|Append( |
|000005f0| 6c 6f 6e 67 20 69 6e 4e | 75 6d 20 29 3b 0d 09 09 |long inN|um );...|
|00000600| 69 6e 6c 69 6e 65 20 76 | 6f 69 64 09 09 09 09 09 |inline v|oid.....|
|00000610| 41 70 70 65 6e 64 28 20 | 63 6f 6e 73 74 20 55 74 |Append( |const Ut|
|00000620| 69 6c 53 74 72 2a 20 69 | 6e 53 74 72 20 29 3b 0d |ilStr* i|nStr );.|
|00000630| 09 09 69 6e 6c 69 6e 65 | 20 76 6f 69 64 09 09 09 |..inline| void...|
|00000640| 09 09 41 70 70 65 6e 64 | 28 20 63 6f 6e 73 74 20 |..Append|( const |
|00000650| 55 74 69 6c 53 74 72 26 | 20 69 6e 53 74 72 20 29 |UtilStr&| inStr )|
|00000660| 09 09 09 09 09 09 09 09 | 7b 20 41 70 70 65 6e 64 |........|{ Append|
|00000670| 28 20 69 6e 53 74 72 2e | 67 65 74 43 53 74 72 28 |( inStr.|getCStr(|
|00000680| 29 2c 20 69 6e 53 74 72 | 2e 6c 65 6e 67 74 68 28 |), inStr|.length(|
|00000690| 29 20 29 3b 09 7d 0d 09 | 09 76 6f 69 64 09 09 09 |) );.}..|.void...|
|000006a0| 09 09 09 41 70 70 65 6e | 64 28 20 63 6f 6e 73 74 |...Appen|d( const|
|000006b0| 20 76 6f 69 64 2a 20 69 | 6e 53 72 63 65 2c 20 6c | void* i|nSrce, l|
|000006c0| 6f 6e 67 20 6e 75 6d 42 | 79 74 65 73 20 29 3b 20 |ong numB|ytes ); |
|000006d0| 0d 09 09 0d 09 09 2f 2f | 09 2a 2a 2a 20 4f 70 65 |......//|.*** Ope|
|000006e0| 72 61 74 6f 72 73 20 2a | 2a 2a 0d 09 09 2f 2f 09 |rators *|**...//.|
|000006f0| 54 68 65 20 2b 20 73 69 | 67 6e 69 66 69 65 73 20 |The + si|gnifies |
|00000700| 41 70 70 65 6e 64 28 29 | 20 61 6e 20 61 70 70 65 |Append()| an appe|
|00000710| 6e 64 20 61 6e 64 20 74 | 68 65 20 3d 20 73 69 67 |nd and t|he = sig|
|00000720| 6e 69 66 69 65 73 20 41 | 73 73 69 67 6e 28 29 0d |nifies A|ssign().|
|00000730| 09 09 55 74 69 6c 53 74 | 72 09 09 09 09 09 09 6f |..UtilSt|r......o|
|00000740| 70 65 72 61 74 6f 72 20 | 2b 20 28 20 63 6f 6e 73 |perator |+ ( cons|
|00000750| 74 20 55 74 69 6c 53 74 | 72 26 20 69 6e 53 74 72 |t UtilSt|r& inStr|
|00000760| 20 29 3b 0d 09 09 55 74 | 69 6c 53 74 72 09 09 09 | );...Ut|ilStr...|
|00000770| 09 09 09 6f 70 65 72 61 | 74 6f 72 20 2b 20 28 20 |...opera|tor + ( |
|00000780| 63 6f 6e 73 74 20 63 68 | 61 72 2a 20 69 6e 43 53 |const ch|ar* inCS|
|00000790| 74 72 20 29 3b 0d 09 09 | 55 74 69 6c 53 74 72 09 |tr );...|UtilStr.|
|000007a0| 09 09 09 09 09 6f 70 65 | 72 61 74 6f 72 20 2b 20 |.....ope|rator + |
|000007b0| 28 20 63 6f 6e 73 74 20 | 6c 6f 6e 67 20 69 6e 4e |( const |long inN|
|000007c0| 75 6d 20 29 3b 0d 09 09 | 55 74 69 6c 53 74 72 26 |um );...|UtilStr&|
|000007d0| 09 09 09 09 09 6f 70 65 | 72 61 74 6f 72 20 3d 20 |.....ope|rator = |
|000007e0| 28 20 63 6f 6e 73 74 20 | 55 74 69 6c 53 74 72 26 |( const |UtilStr&|
|000007f0| 20 69 6e 53 74 72 20 29 | 3b 0d 09 09 0d 09 09 0d | inStr )|;.......|
|00000800| 09 09 2f 2f 09 50 6f 73 | 74 3a 09 09 09 09 09 4d |..//.Pos|t:.....M|
|00000810| 61 6b 65 73 20 74 68 65 | 20 6c 65 6e 67 74 68 20 |akes the| length |
|00000820| 6f 66 20 74 68 69 73 20 | 3c 6e 75 6d 42 79 74 65 |of this |<numByte|
|00000830| 73 3e 2e 0d 09 09 2f 2f | 09 4e 6f 74 65 3a 09 09 |s>....//|.Note:..|
|00000840| 09 09 09 54 68 65 20 64 | 61 74 61 20 69 6e 20 74 |...The d|ata in t|
|00000850| 68 69 73 20 69 73 20 67 | 61 72 62 61 67 65 21 0d |his is g|arbage!.|
|00000860| 09 09 69 6e 6c 69 6e 65 | 20 76 6f 69 64 09 09 09 |..inline| void...|
|00000870| 09 09 44 69 6d 28 20 75 | 6e 73 69 67 6e 65 64 20 |..Dim( u|nsigned |
|00000880| 6c 6f 6e 67 20 6e 75 6d | 42 79 74 65 73 20 29 09 |long num|Bytes ).|
|00000890| 09 09 09 09 09 7b 20 41 | 73 73 69 67 6e 28 20 28 |.....{ A|ssign( (|
|000008a0| 76 6f 69 64 2a 29 20 4e | 55 4c 4c 2c 20 6e 75 6d |void*) N|ULL, num|
|000008b0| 42 79 74 65 73 20 29 3b | 09 09 7d 0d 09 09 0d 09 |Bytes );|..}.....|
|000008c0| 09 2f 2f 09 50 6f 73 74 | 3a 09 53 77 61 70 73 20 |.//.Post|:.Swaps |
|000008d0| 74 68 65 20 69 6e 74 65 | 72 6e 61 6c 20 73 74 72 |the inte|rnal str|
|000008e0| 69 6e 67 20 70 74 72 73 | 2e 20 20 54 68 69 73 20 |ing ptrs|. This |
|000008f0| 66 63 6e 20 69 73 20 75 | 73 65 66 75 6c 20 69 66 |fcn is u|seful if|
|00000900| 20 79 6f 75 20 6e 65 65 | 64 20 74 6f 20 61 73 73 | you nee|d to ass|
|00000910| 69 67 6e 20 61 20 73 74 | 72 69 6e 67 20 76 61 6c |ign a st|ring val|
|00000920| 75 65 20 61 6e 64 20 64 | 6f 6e 27 74 20 63 61 72 |ue and d|on't car|
|00000930| 65 0d 09 09 2f 2f 09 09 | 09 69 66 20 74 68 65 20 |e...//..|.if the |
|00000940| 6f 72 69 67 69 6e 61 6c | 20 73 74 72 69 6e 67 20 |original| string |
|00000950| 63 68 61 6e 67 65 73 2e | 0d 09 09 76 6f 69 64 09 |changes.|...void.|
|00000960| 09 09 09 09 09 53 77 61 | 70 28 20 55 74 69 6c 53 |.....Swa|p( UtilS|
|00000970| 74 72 26 20 69 6f 53 74 | 72 20 29 3b 0d 0d 09 09 |tr& ioSt|r );....|
|00000980| 2f 2f 09 50 6f 73 74 3a | 09 54 68 65 20 6c 65 6e |//.Post:|.The len|
|00000990| 67 74 68 20 6f 66 20 74 | 68 69 73 20 73 74 72 69 |gth of t|his stri|
|000009a0| 6e 67 20 69 73 20 72 65 | 74 75 72 6e 65 64 0d 09 |ng is re|turned..|
|000009b0| 09 69 6e 6c 69 6e 65 20 | 75 6e 73 69 67 6e 65 64 |.inline |unsigned|
|000009c0| 20 6c 6f 6e 67 09 09 6c | 65 6e 67 74 68 28 29 20 | long..l|ength() |
|000009d0| 63 6f 6e 73 74 09 09 09 | 09 09 09 09 09 09 09 7b |const...|.......{|
|000009e0| 20 72 65 74 75 72 6e 20 | 6d 53 74 72 4c 65 6e 3b | return |mStrLen;|
|000009f0| 09 09 09 09 09 09 7d 0d | 09 09 0d 09 09 2f 2f 09 |......}.|.....//.|
|00000a00| 50 6f 73 74 3a 09 52 65 | 74 75 72 6e 73 20 74 68 |Post:.Re|turns th|
|00000a10| 65 20 3c 69 3e 74 68 20 | 63 68 61 72 61 63 74 65 |e <i>th |characte|
|00000a20| 72 20 69 6e 20 74 68 69 | 73 20 73 74 72 69 6e 67 |r in thi|s string|
|00000a30| 2e 20 20 49 66 20 69 20 | 3c 20 31 20 6f 72 20 67 |. If i |< 1 or g|
|00000a40| 72 65 61 74 65 72 20 74 | 68 61 6e 20 6c 65 6e 2c |reater t|han len,|
|00000a50| 20 30 20 69 73 20 72 65 | 74 75 72 6e 65 64 0d 09 | 0 is re|turned..|
|00000a60| 09 63 68 61 72 09 09 09 | 09 09 09 67 65 74 43 68 |.char...|...getCh|
|00000a70| 61 72 28 20 75 6e 73 69 | 67 6e 65 64 20 6c 6f 6e |ar( unsi|gned lon|
|00000a80| 67 20 69 20 29 20 63 6f | 6e 73 74 3b 0d 09 09 0d |g i ) co|nst;....|
|00000a90| 09 09 2f 2f 09 50 6f 73 | 74 3a 09 54 68 65 20 3c |..//.Pos|t:.The <|
|00000aa0| 69 3e 74 68 20 63 68 61 | 72 61 63 74 65 72 20 69 |i>th cha|racter i|
|00000ab0| 73 20 72 65 70 6c 61 63 | 65 64 20 77 69 74 68 20 |s replac|ed with |
|00000ac0| 3c 69 6e 43 68 61 72 3e | 2e 20 20 49 66 20 69 20 |<inChar>|. If i |
|00000ad0| 3c 20 31 20 6f 72 20 67 | 72 65 61 74 65 72 20 74 |< 1 or g|reater t|
|00000ae0| 68 61 6e 20 6c 65 6e 2c | 20 74 68 69 73 0d 09 09 |han len,| this...|
|00000af0| 2f 2f 09 09 09 73 74 72 | 69 6e 67 20 69 73 20 75 |//...str|ing is u|
|00000b00| 6e 61 66 66 65 63 74 65 | 64 2e 0d 09 09 76 6f 69 |naffecte|d....voi|
|00000b10| 64 09 09 09 09 09 09 73 | 65 74 43 68 61 72 28 20 |d......s|etChar( |
|00000b20| 75 6e 73 69 67 6e 65 64 | 20 6c 6f 6e 67 20 69 2c |unsigned| long i,|
|00000b30| 20 63 68 61 72 20 69 6e | 43 68 61 72 20 29 3b 0d | char in|Char );.|
|00000b40| 0d 09 09 2f 2f 09 50 6f | 73 74 3a 09 3c 69 6e 53 |...//.Po|st:.<inS|
|00000b50| 74 72 3e 20 69 73 20 61 | 70 70 65 6e 64 65 64 20 |tr> is a|ppended |
|00000b60| 74 6f 20 74 68 65 20 62 | 65 67 69 6e 6e 69 6e 67 |to the b|eginning|
|00000b70| 20 74 6f 20 74 68 69 73 | 20 73 74 72 69 6e 67 2e | to this| string.|
|00000b80| 0d 09 09 76 6f 69 64 20 | 09 09 09 09 09 09 50 72 |...void |......Pr|
|00000b90| 65 70 65 6e 64 28 20 63 | 6f 6e 73 74 20 63 68 61 |epend( c|onst cha|
|00000ba0| 72 20 69 6e 43 68 61 72 | 29 3b 0d 09 09 76 6f 69 |r inChar|);...voi|
|00000bb0| 64 09 09 09 09 09 09 50 | 72 65 70 65 6e 64 28 20 |d......P|repend( |
|00000bc0| 63 6f 6e 73 74 20 63 68 | 61 72 2a 20 69 6e 53 74 |const ch|ar* inSt|
|00000bd0| 72 20 29 3b 0d 09 09 76 | 6f 69 64 09 09 09 09 09 |r );...v|oid.....|
|00000be0| 09 50 72 65 70 65 6e 64 | 28 20 55 74 69 6c 53 74 |.Prepend|( UtilSt|
|00000bf0| 72 26 20 69 6e 53 74 72 | 20 29 3b 0d 09 09 0d 09 |r& inStr| );.....|
|00000c00| 09 2f 2f 09 50 6f 73 74 | 3a 09 3c 69 6e 53 72 63 |.//.Post|:.<inSrc|
|00000c10| 65 3e 20 28 6f 72 20 3c | 69 6e 4e 75 6d 3e 29 20 |e> (or <|inNum>) |
|00000c20| 69 73 20 69 6e 73 65 72 | 74 65 64 20 69 6e 20 74 |is inser|ted in t|
|00000c30| 68 65 20 73 74 72 69 6e | 67 20 61 66 74 65 72 20 |he strin|g after |
|00000c40| 74 68 65 20 3c 69 6e 50 | 6f 73 3e 74 68 20 63 68 |the <inP|os>th ch|
|00000c50| 61 72 61 63 74 65 72 0d | 09 09 2f 2f 09 4e 6f 74 |aracter.|..//.Not|
|00000c60| 65 3a 09 57 68 65 6e 20 | 3c 69 6e 50 6f 73 3e 20 |e:.When |<inPos> |
|00000c70| 3d 20 30 2c 20 74 68 69 | 73 20 69 73 20 74 68 65 |= 0, thi|s is the|
|00000c80| 20 73 61 6d 65 20 61 73 | 20 50 72 65 70 65 6e 64 | same as| Prepend|
|00000c90| 28 2e 2e 2e 29 0d 09 09 | 2f 2f 09 4e 6f 74 65 3a |(...)...|//.Note:|
|00000ca0| 09 49 66 20 3c 69 6e 50 | 6f 73 3e 20 69 73 20 67 |.If <inP|os> is g|
|00000cb0| 72 65 61 74 65 72 20 74 | 68 65 6e 20 6f 72 20 65 |reater t|hen or e|
|00000cc0| 71 75 61 6c 20 74 6f 20 | 74 68 65 20 6c 65 6e 67 |qual to |the leng|
|00000cd0| 74 68 20 6f 66 20 74 68 | 69 73 20 73 74 72 2c 20 |th of th|is str, |
|00000ce0| 3c 69 6e 53 72 63 65 3e | 20 69 73 20 61 70 70 65 |<inSrce>| is appe|
|00000cf0| 6e 64 65 64 20 74 6f 20 | 74 68 65 20 65 6e 64 0d |nded to |the end.|
|00000d00| 09 09 2f 2f 09 09 09 22 | 48 69 46 72 65 64 22 2e |..//..."|HiFred".|
|00000d10| 49 6e 73 65 72 74 28 20 | 32 2c 20 22 2c 22 20 29 |Insert( |2, "," )|
|00000d20| 20 20 2d 2d 2d 3e 20 20 | 22 48 69 2c 46 72 65 64 | ---> |"Hi,Fred|
|00000d30| 22 0d 09 09 76 6f 69 64 | 09 09 09 09 09 09 49 6e |"...void|......In|
|00000d40| 73 65 72 74 28 20 75 6e | 73 69 67 6e 65 64 20 6c |sert( un|signed l|
|00000d50| 6f 6e 67 20 69 6e 50 6f | 73 2c 20 63 6f 6e 73 74 |ong inPo|s, const|
|00000d60| 20 55 74 69 6c 53 74 72 | 26 20 69 6e 53 72 63 65 | UtilStr|& inSrce|
|00000d70| 20 29 3b 0d 09 09 76 6f | 69 64 09 09 09 09 09 09 | );...vo|id......|
|00000d80| 49 6e 73 65 72 74 28 20 | 75 6e 73 69 67 6e 65 64 |Insert( |unsigned|
|00000d90| 20 6c 6f 6e 67 20 69 6e | 50 6f 73 2c 20 63 6f 6e | long in|Pos, con|
|00000da0| 73 74 20 63 68 61 72 2a | 20 69 6e 53 72 63 65 2c |st char*| inSrce,|
|00000db0| 20 6c 6f 6e 67 20 69 6e | 53 72 63 65 4c 65 6e 20 | long in|SrceLen |
|00000dc0| 29 3b 0d 09 09 76 6f 69 | 64 09 09 09 09 09 09 49 |);...voi|d......I|
|00000dd0| 6e 73 65 72 74 28 20 75 | 6e 73 69 67 6e 65 64 20 |nsert( u|nsigned |
|00000de0| 6c 6f 6e 67 20 69 6e 50 | 6f 73 2c 20 63 68 61 72 |long inP|os, char|
|00000df0| 20 69 6e 43 68 61 72 2c | 20 6c 6f 6e 67 20 69 6e | inChar,| long in|
|00000e00| 4e 75 6d 54 69 6d 65 73 | 20 29 3b 0d 09 09 76 6f |NumTimes| );...vo|
|00000e10| 69 64 09 09 09 09 09 09 | 49 6e 73 65 72 74 28 20 |id......|Insert( |
|00000e20| 75 6e 73 69 67 6e 65 64 | 20 6c 6f 6e 67 20 69 6e |unsigned| long in|
|00000e30| 50 6f 73 2c 20 6c 6f 6e | 67 20 69 6e 4e 75 6d 20 |Pos, lon|g inNum |
|00000e40| 29 3b 0d 09 09 09 09 0d | 09 09 2f 2f 09 50 6f 73 |);......|..//.Pos|
|00000e50| 74 3a 09 52 65 74 75 72 | 6e 73 20 61 20 70 74 72 |t:.Retur|ns a ptr|
|00000e60| 20 74 6f 20 61 20 70 61 | 73 63 61 6c 20 73 74 79 | to a pa|scal sty|
|00000e70| 6c 65 20 73 74 72 69 6e | 67 20 6f 66 20 74 68 69 |le strin|g of thi|
|00000e80| 73 20 73 74 72 69 6e 67 | 2e 20 20 52 65 6d 65 6d |s string|. Remem|
|00000e90| 62 65 72 20 74 68 61 74 | 20 69 66 20 74 68 69 73 |ber that| if this|
|00000ea0| 20 73 74 72 69 6e 67 20 | 69 73 20 67 72 65 61 74 | string |is great|
|00000eb0| 65 72 20 74 68 61 6e 0d | 09 09 2f 2f 09 09 09 32 |er than.|..//...2|
|00000ec0| 35 35 20 63 68 61 72 73 | 2c 20 6f 6e 6c 79 20 74 |55 chars|, only t|
|00000ed0| 68 65 20 66 69 72 73 74 | 20 32 35 35 20 63 61 6e |he first| 255 can|
|00000ee0| 20 62 65 20 61 63 63 65 | 73 73 65 64 2e 20 20 2a | be acce|ssed. *|
|00000ef0| 4e 4f 54 45 3a 20 54 68 | 69 73 20 66 63 6e 20 69 |NOTE: Th|is fcn i|
|00000f00| 73 20 64 65 73 69 67 6e | 65 64 20 66 6f 72 0d 09 |s design|ed for..|
|00000f10| 09 2f 2f 09 09 09 69 6e | 73 74 61 6e 74 61 6e 69 |.//...in|stantani|
|00000f20| 6f 75 73 20 75 73 65 20 | 28 69 65 2c 20 69 66 20 |ous use |(ie, if |
|00000f30| 79 6f 75 20 63 68 61 6e | 67 65 20 74 68 65 20 73 |you chan|ge the s|
|00000f40| 74 72 69 6e 67 20 61 74 | 20 61 6c 6c 2c 20 79 6f |tring at| all, yo|
|00000f50| 75 20 2a 6d 75 73 74 2a | 20 72 65 2d 63 61 6c 6c |u *must*| re-call|
|00000f60| 20 74 68 69 73 20 6d 65 | 74 68 6f 64 29 2e 20 20 | this me|thod). |
|00000f70| 49 6e 20 6f 74 68 65 72 | 20 77 6f 72 64 73 2c 0d |In other| words,.|
|00000f80| 09 09 2f 2f 09 09 09 74 | 72 65 61 74 20 74 68 65 |..//...t|reat the|
|00000f90| 20 70 74 72 20 72 65 74 | 75 72 6e 65 64 20 61 73 | ptr ret|urned as|
|00000fa0| 20 2a 72 65 61 64 2a 20 | 6f 6e 6c 79 21 0d 09 09 | *read* |only!...|
|00000fb0| 75 6e 73 69 67 6e 65 64 | 20 63 68 61 72 2a 09 09 |unsigned| char*..|
|00000fc0| 09 09 67 65 74 50 61 73 | 53 74 72 28 29 20 63 6f |..getPas|Str() co|
|00000fd0| 6e 73 74 3b 0d 09 09 0d | 09 09 2f 2f 09 50 6f 73 |nst;....|..//.Pos|
|00000fe0| 74 3a 09 52 65 74 75 72 | 6e 73 20 61 20 70 74 72 |t:.Retur|ns a ptr|
|00000ff0| 20 74 6f 20 61 20 43 20 | 73 74 79 6c 65 20 73 74 | to a C |style st|
|00001000| 72 69 6e 67 20 6f 66 20 | 74 68 69 73 20 73 74 72 |ring of |this str|
|00001010| 69 6e 67 2e 20 20 2a 4e | 4f 54 45 3a 20 54 68 69 |ing. *N|OTE: Thi|
|00001020| 73 20 66 63 6e 20 69 73 | 20 64 65 73 69 67 6e 65 |s fcn is| designe|
|00001030| 64 20 66 6f 72 0d 09 09 | 2f 2f 09 09 09 69 6e 73 |d for...|//...ins|
|00001040| 74 61 6e 74 61 6e 69 6f | 75 73 20 75 73 65 20 28 |tantanio|us use (|
|00001050| 69 65 2c 20 69 66 20 79 | 6f 75 20 63 68 61 6e 67 |ie, if y|ou chang|
|00001060| 65 20 74 68 65 20 73 74 | 72 69 6e 67 20 61 74 20 |e the st|ring at |
|00001070| 61 6c 6c 2c 20 79 6f 75 | 20 2a 6d 75 73 74 2a 20 |all, you| *must* |
|00001080| 72 65 2d 63 61 6c 6c 20 | 74 68 69 73 20 6d 65 74 |re-call |this met|
|00001090| 68 6f 64 29 2e 20 49 6e | 20 6f 74 68 65 72 20 77 |hod). In| other w|
|000010a0| 6f 72 64 73 2c 0d 09 09 | 2f 2f 09 09 09 74 72 65 |ords,...|//...tre|
|000010b0| 61 74 20 74 68 65 20 70 | 74 72 20 72 65 74 75 72 |at the p|tr retur|
|000010c0| 6e 65 64 20 61 73 20 2a | 72 65 61 64 2a 20 6f 6e |ned as *|read* on|
|000010d0| 6c 79 21 0d 09 09 63 68 | 61 72 2a 09 09 09 09 09 |ly!...ch|ar*.....|
|000010e0| 09 67 65 74 43 53 74 72 | 28 29 20 63 6f 6e 73 74 |.getCStr|() const|
|000010f0| 3b 0d 09 09 0d 09 09 2f | 2f 09 50 6f 73 74 3a 09 |;....../|/.Post:.|
|00001100| 54 68 69 73 20 73 74 72 | 69 6e 67 20 69 73 20 65 |This str|ing is e|
|00001110| 6d 70 74 69 65 64 20 28 | 6c 65 6e 67 74 68 20 69 |mptied (|length i|
|00001120| 73 20 7a 65 72 6f 29 0d | 09 09 69 6e 6c 69 6e 65 |s zero).|..inline|
|00001130| 20 76 6f 69 64 20 09 09 | 09 09 57 69 70 65 28 29 | void ..|..Wipe()|
|00001140| 09 09 09 09 09 09 09 09 | 09 09 09 09 09 09 7b 20 |........|......{ |
|00001150| 6d 53 74 72 4c 65 6e 20 | 3d 20 30 3b 09 09 7d 0d |mStrLen |= 0;..}.|
|00001160| 09 09 0d 09 09 2f 2f 09 | 50 6f 73 74 3a 09 52 65 |.....//.|Post:.Re|
|00001170| 70 6c 61 63 65 73 20 61 | 6c 6c 20 69 6e 73 74 61 |places a|ll insta|
|00001180| 6e 63 65 73 20 6f 66 20 | 3c 69 6e 54 61 72 67 65 |nces of |<inTarge|
|00001190| 74 3e 20 77 69 74 68 20 | 3c 69 6e 52 65 70 6c 61 |t> with |<inRepla|
|000011a0| 63 65 6d 65 6e 74 3e 0d | 09 09 76 6f 69 64 09 09 |cement>.|..void..|
|000011b0| 09 09 09 09 52 65 70 6c | 61 63 65 28 20 63 68 61 |....Repl|ace( cha|
|000011c0| 72 20 69 6e 54 61 72 67 | 65 74 2c 20 63 68 61 72 |r inTarg|et, char|
|000011d0| 20 69 6e 52 65 70 6c 61 | 63 65 6d 65 6e 74 20 29 | inRepla|cement )|
|000011e0| 3b 0d 09 09 0d 09 09 2f | 2f 09 50 6f 73 74 3a 09 |;....../|/.Post:.|
|000011f0| 54 72 75 6e 63 61 74 65 | 73 20 3c 6e 75 6d 54 6f |Truncate|s <numTo|
|00001200| 43 68 6f 70 3e 20 63 68 | 61 72 73 20 66 72 6f 6d |Chop> ch|ars from|
|00001210| 20 74 68 69 73 20 73 74 | 72 69 6e 67 2c 20 65 69 | this st|ring, ei|
|00001220| 74 68 65 72 20 66 72 6f | 6d 20 74 68 65 20 72 69 |ther fro|m the ri|
|00001230| 67 68 74 20 6f 72 20 6c | 65 66 74 2e 20 20 49 66 |ght or l|eft. If|
|00001240| 20 3c 6e 75 6d 54 6f 43 | 68 6f 70 3e 20 69 73 0d | <numToC|hop> is.|
|00001250| 09 09 2f 2f 09 09 09 6c | 65 73 73 20 74 68 61 6e |..//...l|ess than|
|00001260| 20 31 2c 20 74 68 69 73 | 20 73 74 72 69 6e 67 20 | 1, this| string |
|00001270| 69 73 20 75 6e 61 66 66 | 65 63 74 65 64 2e 20 20 |is unaff|ected. |
|00001280| 49 66 20 3c 6e 75 6d 54 | 6f 43 68 6f 70 3e 20 69 |If <numT|oChop> i|
|00001290| 73 20 67 72 65 61 74 65 | 72 20 6f 72 20 65 71 75 |s greate|r or equ|
|000012a0| 61 6c 20 74 6f 20 74 68 | 65 20 6c 65 6e 67 74 68 |al to th|e length|
|000012b0| 0d 09 09 2f 2f 09 09 09 | 69 66 20 74 68 69 73 20 |...//...|if this |
|000012c0| 73 74 72 69 6e 67 2c 20 | 74 68 65 20 73 74 72 69 |string, |the stri|
|000012d0| 6e 67 20 69 73 20 65 6d | 70 74 69 65 64 2e 0d 09 |ng is em|ptied...|
|000012e0| 09 76 6f 69 64 09 09 09 | 09 09 09 54 72 75 6e 63 |.void...|...Trunc|
|000012f0| 28 20 75 6e 73 69 67 6e | 65 64 20 6c 6f 6e 67 20 |( unsign|ed long |
|00001300| 6e 75 6d 54 6f 43 68 6f | 70 2c 20 62 6f 6f 6c 20 |numToCho|p, bool |
|00001310| 66 72 6f 6d 52 69 67 68 | 74 20 3d 20 74 72 75 65 |fromRigh|t = true|
|00001320| 20 29 3b 0d 09 09 0d 09 | 09 2f 2f 09 50 6f 73 74 | );.....|.//.Post|
|00001330| 3a 09 41 74 20 70 6f 73 | 69 74 69 6f 6e 20 3c 69 |:.At pos|ition <i|
|00001340| 6e 50 6f 73 3e 20 69 6e | 20 74 68 65 20 73 74 72 |nPos> in| the str|
|00001350| 69 6e 67 2c 20 3c 69 6e | 4e 75 6d 3e 20 63 68 61 |ing, <in|Num> cha|
|00001360| 72 61 63 74 65 72 73 20 | 61 72 65 20 72 65 6d 6f |racters |are remo|
|00001370| 76 65 64 0d 09 09 2f 2f | 09 09 09 22 48 69 2c 46 |ved...//|..."Hi,F|
|00001380| 72 65 64 22 2e 52 65 6d | 6f 76 65 28 20 33 2c 20 |red".Rem|ove( 3, |
|00001390| 31 20 29 20 20 2d 2d 2d | 3e 20 20 22 48 69 46 72 |1 ) ---|> "HiFr|
|000013a0| 65 64 22 0d 09 09 76 6f | 69 64 09 09 09 09 09 09 |ed"...vo|id......|
|000013b0| 52 65 6d 6f 76 65 28 20 | 75 6e 73 69 67 6e 65 64 |Remove( |unsigned|
|000013c0| 20 6c 6f 6e 67 20 69 6e | 50 6f 73 2c 20 75 6e 73 | long in|Pos, uns|
|000013d0| 69 67 6e 65 64 20 6c 6f | 6e 67 20 69 6e 4e 75 6d |igned lo|ng inNum|
|000013e0| 20 29 3b 0d 09 09 0d 09 | 09 2f 2f 09 50 6f 73 74 | );.....|.//.Post|
|000013f0| 3a 09 41 6c 6c 20 69 6e | 73 74 61 6e 63 65 73 20 |:.All in|stances |
|00001400| 6f 66 20 61 20 67 69 76 | 65 6e 20 73 74 72 69 6e |of a giv|en strin|
|00001410| 67 20 61 72 65 20 72 65 | 6d 6f 76 65 64 20 66 72 |g are re|moved fr|
|00001420| 6f 6d 20 74 68 69 73 20 | 73 74 72 69 6e 67 0d 09 |om this |string..|
|00001430| 09 2f 2f 09 4e 6f 74 65 | 3a 09 69 6e 4c 65 6e 20 |.//.Note|:.inLen |
|00001440| 69 73 20 74 68 65 20 6c | 65 6e 67 74 68 20 6f 66 |is the l|ength of|
|00001450| 20 69 6e 53 74 72 2e 20 | 20 49 66 20 69 6e 4c 65 | inStr. | If inLe|
|00001460| 6e 20 3c 20 2d 31 2c 20 | 74 68 65 20 6c 65 6e 67 |n < -1, |the leng|
|00001470| 74 68 20 6f 66 20 69 6e | 53 74 72 20 69 73 20 63 |th of in|Str is c|
|00001480| 61 6c 63 75 6c 61 74 65 | 64 0d 09 09 76 6f 69 64 |alculate|d...void|
|00001490| 09 09 09 09 09 09 52 65 | 6d 6f 76 65 28 20 63 68 |......Re|move( ch|
|000014a0| 61 72 2a 20 69 6e 53 74 | 72 2c 20 69 6e 74 20 69 |ar* inSt|r, int i|
|000014b0| 6e 4c 65 6e 20 3d 20 2d | 31 2c 20 62 6f 6f 6c 20 |nLen = -|1, bool |
|000014c0| 69 6e 43 61 73 65 53 65 | 6e 73 69 74 69 76 65 20 |inCaseSe|nsitive |
|000014d0| 3d 20 74 72 75 65 20 29 | 3b 0d 09 09 0d 09 09 2f |= true )|;....../|
|000014e0| 2f 09 50 6f 73 74 3a 09 | 54 72 75 6e 63 61 74 65 |/.Post:.|Truncate|
|000014f0| 73 20 61 66 74 65 72 20 | 74 68 65 20 3c 69 6e 4e |s after |the <inN|
|00001500| 75 6d 54 6f 4b 65 65 70 | 3e 74 68 20 63 68 61 72 |umToKeep|>th char|
|00001510| 61 63 74 65 72 2e 20 20 | 49 66 20 3c 69 6e 4e 75 |acter. |If <inNu|
|00001520| 6d 54 6f 4b 65 65 70 3e | 20 69 73 20 67 72 65 61 |mToKeep>| is grea|
|00001530| 74 65 72 20 74 68 61 6e | 20 6f 72 20 65 71 75 61 |ter than| or equa|
|00001540| 6c 20 74 6f 0d 09 09 2f | 2f 09 09 09 74 68 65 20 |l to.../|/...the |
|00001550| 6c 65 6e 67 74 68 2c 20 | 6e 6f 74 68 69 6e 67 20 |length, |nothing |
|00001560| 68 61 70 70 65 6e 73 2e | 0d 09 09 76 6f 69 64 09 |happens.|...void.|
|00001570| 09 09 09 09 09 4b 65 65 | 70 28 20 75 6e 73 69 67 |.....Kee|p( unsig|
|00001580| 6e 65 64 20 6c 6f 6e 67 | 20 69 6e 4e 75 6d 54 6f |ned long| inNumTo|
|00001590| 4b 65 65 70 20 29 3b 0d | 09 09 0d 09 09 2f 2f 09 |Keep );.|.....//.|
|000015a0| 50 6f 73 74 3a 09 49 66 | 20 74 68 69 73 27 20 6c |Post:.If| this' l|
|000015b0| 65 6e 20 69 73 20 6c 61 | 72 67 65 72 20 74 68 61 |en is la|rger tha|
|000015c0| 6e 20 3c 69 6e 4d 61 78 | 4c 65 6e 3e 2c 20 61 20 |n <inMax|Len>, a |
|000015d0| 27 c9 27 20 72 65 70 6c | 61 63 65 73 20 74 68 65 |'.' repl|aces the|
|000015e0| 20 3c 69 6e 50 6f 73 3e | 74 68 20 63 68 61 72 61 | <inPos>|th chara|
|000015f0| 63 74 65 72 20 61 6e 64 | 20 63 68 61 72 73 20 61 |cter and| chars a|
|00001600| 72 65 20 72 65 6d 6f 76 | 65 64 20 0d 09 09 2f 2f |re remov|ed ...//|
|00001610| 09 09 09 61 66 74 65 72 | 20 74 68 65 20 27 c9 27 |...after| the '.'|
|00001620| 20 75 6e 74 69 6c 20 74 | 68 65 20 74 68 69 73 27 | until t|he this'|
|00001630| 20 6c 65 6e 67 74 68 20 | 69 73 20 3c 69 6e 4d 61 | length |is <inMa|
|00001640| 78 4c 65 6e 3e 0d 09 09 | 76 6f 69 64 09 09 09 09 |xLen>...|void....|
|00001650| 09 09 50 6f 6c 69 74 65 | 4b 65 65 70 28 20 75 6e |..Polite|Keep( un|
|00001660| 73 69 67 6e 65 64 20 6c | 6f 6e 67 20 69 6e 4d 61 |signed l|ong inMa|
|00001670| 78 4c 65 6e 2c 20 75 6e | 73 69 67 6e 65 64 20 6c |xLen, un|signed l|
|00001680| 6f 6e 67 20 69 6e 50 6f | 73 20 29 3b 0d 0d 09 09 |ong inPo|s );....|
|00001690| 2f 2f 09 50 6f 73 74 3a | 09 41 20 73 69 6d 70 6c |//.Post:|.A simpl|
|000016a0| 65 20 66 69 6c 74 65 72 | 20 74 68 61 74 20 64 65 |e filter| that de|
|000016b0| 63 61 70 69 74 61 6c 69 | 7a 65 64 20 61 6c 6c 20 |capitali|zed all |
|000016c0| 63 68 61 72 73 20 74 68 | 61 74 20 61 72 65 6e 27 |chars th|at aren'|
|000016d0| 74 20 74 68 65 20 66 69 | 72 73 74 20 69 6e 20 65 |t the fi|rst in e|
|000016e0| 61 63 68 20 77 6f 72 64 | 2e 0d 09 09 76 6f 69 64 |ach word|....void|
|000016f0| 09 09 09 09 09 09 44 65 | 63 61 70 69 74 61 6c 69 |......De|capitali|
|00001700| 7a 65 28 29 3b 0d 09 09 | 0d 09 09 2f 2f 09 50 6f |ze();...|...//.Po|
|00001710| 73 74 3a 09 43 61 70 69 | 74 61 6c 69 7a 65 73 20 |st:.Capi|talizes |
|00001720| 61 6c 6c 20 74 68 65 20 | 63 68 61 72 73 20 69 6e |all the |chars in|
|00001730| 20 74 68 69 73 20 73 74 | 72 69 6e 67 2e 0d 09 09 | this st|ring....|
|00001740| 76 6f 69 64 09 09 09 09 | 09 09 43 61 70 69 74 61 |void....|..Capita|
|00001750| 6c 69 7a 65 28 29 3b 0d | 09 09 0d 09 09 2f 2f 09 |lize();.|.....//.|
|00001760| 50 6f 73 74 3a 09 52 65 | 6d 6f 76 65 73 20 61 6e |Post:.Re|moves an|
|00001770| 79 20 6c 65 61 64 69 6e | 67 20 73 70 61 63 65 73 |y leadin|g spaces|
|00001780| 20 69 6e 20 74 68 69 73 | 20 73 74 72 69 6e 67 2e | in this| string.|
|00001790| 20 0d 09 09 76 6f 69 64 | 09 09 09 09 09 09 5a 61 | ...void|......Za|
|000017a0| 70 4c 65 61 64 69 6e 67 | 53 70 61 63 65 73 28 29 |pLeading|Spaces()|
|000017b0| 3b 0d 09 09 0d 09 09 2f | 2f 09 50 72 65 3a 09 3c |;....../|/.Pre:.<|
|000017c0| 70 61 73 44 65 73 74 50 | 74 72 3e 20 70 6f 69 6e |pasDestP|tr> poin|
|000017d0| 74 73 20 74 6f 20 61 20 | 70 61 73 63 61 6c 20 73 |ts to a |pascal s|
|000017e0| 74 72 69 6e 67 20 6f 66 | 20 6c 65 6e 67 74 68 20 |tring of| length |
|000017f0| 3c 69 6e 42 79 74 65 73 | 54 6f 43 6f 70 79 3e 0d |<inBytes|ToCopy>.|
|00001800| 09 09 2f 2f 09 50 6f 73 | 74 3a 09 54 68 65 20 63 |..//.Pos|t:.The c|
|00001810| 6f 6e 74 65 6e 74 73 20 | 6f 66 20 74 68 69 73 20 |ontents |of this |
|00001820| 73 74 72 69 6e 67 20 69 | 73 20 63 6f 70 69 65 64 |string i|s copied|
|00001830| 20 74 6f 20 3c 70 61 73 | 44 65 73 74 50 74 72 3e | to <pas|DestPtr>|
|00001840| 2c 20 75 70 64 61 74 69 | 6e 67 20 69 74 73 20 6c |, updati|ng its l|
|00001850| 65 6e 67 74 68 20 62 79 | 74 65 0d 09 09 76 6f 69 |ength by|te...voi|
|00001860| 64 09 09 09 09 09 09 63 | 6f 70 79 54 6f 28 20 75 |d......c|opyTo( u|
|00001870| 6e 73 69 67 6e 65 64 20 | 63 68 61 72 2a 20 70 61 |nsigned |char* pa|
|00001880| 73 44 65 73 74 50 74 72 | 2c 20 75 6e 73 69 67 6e |sDestPtr|, unsign|
|00001890| 65 64 20 63 68 61 72 20 | 69 6e 42 79 74 65 73 54 |ed char |inBytesT|
|000018a0| 6f 43 6f 70 79 20 29 20 | 63 6f 6e 73 74 3b 0d 09 |oCopy ) |const;..|
|000018b0| 09 0d 09 09 2f 2f 09 50 | 72 65 3a 09 3c 63 44 65 |....//.P|re:.<cDe|
|000018c0| 73 74 50 74 72 3e 20 70 | 6f 69 6e 74 73 20 74 6f |stPtr> p|oints to|
|000018d0| 20 61 20 63 20 73 74 72 | 69 6e 67 20 77 69 74 68 | a c str|ing with|
|000018e0| 20 61 6e 20 61 6c 6c 6f | 63 61 74 65 64 20 6c 65 | an allo|cated le|
|000018f0| 6e 67 74 68 20 6f 66 20 | 3c 69 6e 42 79 74 65 73 |ngth of |<inBytes|
|00001900| 54 6f 43 6f 70 79 3e 0d | 09 09 2f 2f 09 50 6f 73 |ToCopy>.|..//.Pos|
|00001910| 74 3a 09 54 68 65 20 63 | 6f 6e 74 65 6e 74 73 20 |t:.The c|ontents |
|00001920| 6f 66 20 74 68 69 73 20 | 73 74 72 69 6e 67 20 69 |of this |string i|
|00001930| 73 20 63 6f 70 69 65 64 | 20 74 6f 20 3c 63 44 65 |s copied| to <cDe|
|00001940| 73 74 50 74 72 3e 2c 20 | 61 70 70 65 6e 64 69 6e |stPtr>, |appendin|
|00001950| 67 20 74 68 65 20 4e 55 | 4c 20 62 79 74 65 0d 09 |g the NU|L byte..|
|00001960| 09 76 6f 69 64 09 09 09 | 09 09 09 63 6f 70 79 54 |.void...|...copyT|
|00001970| 6f 28 20 63 68 61 72 2a | 20 63 44 65 73 74 50 74 |o( char*| cDestPt|
|00001980| 72 2c 20 75 6e 73 69 67 | 6e 65 64 20 6c 6f 6e 67 |r, unsig|ned long|
|00001990| 20 69 6e 42 79 74 65 73 | 54 6f 43 6f 70 79 20 29 | inBytes|ToCopy )|
|000019a0| 20 63 6f 6e 73 74 3b 0d | 09 09 0d 09 09 2f 2f 09 | const;.|.....//.|
|000019b0| 50 6f 73 74 3a 09 54 68 | 69 73 20 73 74 72 69 6e |Post:.Th|is strin|
|000019c0| 67 20 69 73 20 72 65 61 | 64 20 66 72 6f 6d 20 3c |g is rea|d from <|
|000019d0| 69 6e 46 69 6c 65 3e 20 | 66 72 6f 6d 20 74 68 65 |inFile> |from the|
|000019e0| 20 63 75 72 72 65 6e 74 | 20 66 69 6c 65 20 70 6f | current| file po|
|000019f0| 73 69 74 69 6f 6e 0d 09 | 09 76 6f 69 64 09 09 09 |sition..|.void...|
|00001a00| 09 09 09 52 65 61 64 46 | 72 6f 6d 28 20 43 45 67 |...ReadF|rom( CEg|
|00001a10| 49 53 74 72 65 61 6d 2a | 20 69 6e 53 74 72 65 61 |IStream*| inStrea|
|00001a20| 6d 20 29 3b 0d 09 09 0d | 09 09 2f 2f 09 50 6f 73 |m );....|..//.Pos|
|00001a30| 74 3a 09 54 68 69 73 20 | 73 74 72 69 6e 67 20 77 |t:.This |string w|
|00001a40| 72 69 74 65 73 20 69 74 | 73 65 6c 66 20 74 6f 20 |rites it|self to |
|00001a50| 3c 69 6e 53 74 72 65 61 | 6d 3e 20 61 74 20 74 68 |<inStrea|m> at th|
|00001a60| 65 20 63 75 72 72 65 6e | 74 20 66 69 6c 65 20 70 |e curren|t file p|
|00001a70| 6f 73 69 74 69 6f 6e 0d | 09 09 76 6f 69 64 09 09 |osition.|..void..|
|00001a80| 09 09 09 09 57 72 69 74 | 65 54 6f 28 20 43 45 67 |....Writ|eTo( CEg|
|00001a90| 4f 53 74 72 65 61 6d 2a | 20 69 6e 53 74 72 65 61 |OStream*| inStrea|
|00001aa0| 6d 20 29 20 63 6f 6e 73 | 74 3b 0d 09 09 0d 09 09 |m ) cons|t;......|
|00001ab0| 2f 2f 09 50 6f 73 74 3a | 09 52 65 74 75 72 6e 73 |//.Post:|.Returns|
|00001ac0| 20 74 68 65 20 72 61 74 | 69 6f 6e 61 6c 20 76 61 | the rat|ional va|
|00001ad0| 6c 75 65 20 6f 66 20 74 | 68 69 73 20 73 74 72 69 |lue of t|his stri|
|00001ae0| 6e 67 20 74 69 6d 65 73 | 20 3c 69 6e 4d 75 6c 74 |ng times| <inMult|
|00001af0| 69 70 6c 69 65 72 3e 2e | 20 20 41 6c 6c 20 63 68 |iplier>.| All ch|
|00001b00| 61 72 73 20 6e 6f 74 20 | 27 30 27 2e 2e 27 39 27 |ars not |'0'..'9'|
|00001b10| 20 61 72 65 0d 09 09 2f | 2f 09 09 09 69 67 6e 6f | are.../|/...igno|
|00001b20| 72 65 64 2c 20 65 78 63 | 65 70 74 20 61 20 6c 65 |red, exc|ept a le|
|00001b30| 61 64 69 6e 67 20 27 2d | 27 20 61 6e 64 20 61 20 |ading '-|' and a |
|00001b40| 27 2e 27 2c 20 77 68 65 | 72 65 20 74 68 65 20 64 |'.', whe|re the d|
|00001b50| 69 67 69 74 73 20 74 68 | 61 74 20 66 6f 6c 6c 6f |igits th|at follo|
|00001b60| 77 20 61 72 65 20 64 65 | 63 69 6d 61 6c 20 64 69 |w are de|cimal di|
|00001b70| 67 69 74 73 0d 09 09 2f | 2f 09 55 73 61 67 65 3a |gits.../|/.Usage:|
|00001b80| 09 22 31 32 2e 33 34 22 | 2e 47 65 74 56 61 6c 75 |."12.34"|.GetValu|
|00001b90| 65 28 20 32 30 20 29 20 | 77 69 6c 6c 20 72 65 74 |e( 20 ) |will ret|
|00001ba0| 75 72 6e 20 32 34 36 0d | 09 09 6c 6f 6e 67 09 09 |urn 246.|..long..|
|00001bb0| 09 09 09 09 47 65 74 56 | 61 6c 75 65 28 20 6c 6f |....GetV|alue( lo|
|00001bc0| 6e 67 20 69 6e 4d 75 6c | 74 69 70 6c 69 65 72 20 |ng inMul|tiplier |
|00001bd0| 3d 20 31 20 29 20 63 6f | 6e 73 74 3b 0d 09 09 0d |= 1 ) co|nst;....|
|00001be0| 09 09 2f 2f 20 09 50 6f | 73 74 3a 09 52 65 74 75 |..// .Po|st:.Retu|
|00001bf0| 72 6e 73 20 61 20 66 6c | 6f 61 74 69 6e 67 20 70 |rns a fl|oating p|
|00001c00| 6f 69 6e 74 20 76 61 6c | 75 65 20 6f 66 20 74 68 |oint val|ue of th|
|00001c10| 69 73 20 73 74 72 69 6e | 67 0d 09 09 64 6f 75 62 |is strin|g...doub|
|00001c20| 6c 65 09 09 09 09 09 09 | 47 65 74 46 6c 6f 61 74 |le......|GetFloat|
|00001c30| 56 61 6c 75 65 28 29 20 | 63 6f 6e 73 74 3b 0d 09 |Value() |const;..|
|00001c40| 09 09 09 0d 09 09 2f 2f | 09 50 72 65 3a 09 3c 69 |......//|.Pre:.<i|
|00001c50| 6e 44 69 76 69 73 6f 72 | 3e 20 21 3d 20 30 0d 09 |nDivisor|> != 0..|
|00001c60| 09 2f 2f 09 09 09 3c 69 | 6e 4e 75 6d 44 65 63 50 |.//...<i|nNumDecP|
|00001c70| 6c 61 63 65 73 3e 20 3c | 20 38 0d 09 09 2f 2f 09 |laces> <| 8...//.|
|00001c80| 50 6f 73 74 3a 09 41 73 | 73 69 67 6e 73 20 74 68 |Post:.As|signs th|
|00001c90| 65 20 73 74 72 69 6e 67 | 20 65 71 75 69 76 69 6c |e string| equivil|
|00001ca0| 65 6e 74 20 6f 66 20 3c | 69 6e 56 61 6c 3e 2f 3c |ent of <|inVal>/<|
|00001cb0| 69 6e 44 69 76 69 73 6f | 72 3e 20 74 6f 20 74 68 |inDiviso|r> to th|
|00001cc0| 69 73 20 73 74 72 69 6e | 67 2c 20 74 72 75 6e 63 |is strin|g, trunc|
|00001cd0| 61 74 69 6e 67 20 74 68 | 65 20 73 74 72 69 6e 67 |ating th|e string|
|00001ce0| 0d 09 09 2f 2f 09 09 09 | 61 66 74 65 72 20 3c 69 |...//...|after <i|
|00001cf0| 6e 4e 75 6d 44 65 63 50 | 6c 61 63 65 73 3e 20 64 |nNumDecP|laces> d|
|00001d00| 65 63 69 6d 61 6c 20 70 | 6c 61 63 65 73 2e 0d 09 |ecimal p|laces...|
|00001d10| 09 2f 2f 09 55 73 61 67 | 65 3a 09 53 65 74 56 61 |.//.Usag|e:.SetVa|
|00001d20| 6c 75 65 28 20 32 34 36 | 38 36 2c 20 32 30 2c 20 |lue( 246|86, 20, |
|00001d30| 32 20 29 20 77 6f 75 6c | 64 20 61 73 73 69 67 6e |2 ) woul|d assign|
|00001d40| 20 74 68 69 73 20 73 74 | 72 69 6e 67 20 74 6f 20 | this st|ring to |
|00001d50| 22 31 32 2e 33 34 22 0d | 09 09 76 6f 69 64 09 09 |"12.34".|..void..|
|00001d60| 09 09 09 09 53 65 74 56 | 61 6c 75 65 28 20 6c 6f |....SetV|alue( lo|
|00001d70| 6e 67 20 69 6e 56 61 6c | 2c 20 6c 6f 6e 67 20 69 |ng inVal|, long i|
|00001d80| 6e 44 69 76 69 73 6f 72 | 20 3d 20 31 2c 20 69 6e |nDivisor| = 1, in|
|00001d90| 74 20 69 6e 4e 75 6d 44 | 65 63 50 6c 61 63 65 73 |t inNumD|ecPlaces|
|00001da0| 20 3d 20 35 20 29 3b 0d | 09 09 0d 09 09 2f 2f 09 | = 5 );.|.....//.|
|00001db0| 50 6f 73 74 3a 09 41 73 | 73 69 67 6e 73 20 74 68 |Post:.As|signs th|
|00001dc0| 69 73 20 73 74 72 69 6e | 67 20 74 68 65 20 72 6f |is strin|g the ro|
|00001dd0| 6d 61 6e 20 6e 75 6d 65 | 72 61 6c 20 73 74 72 69 |man nume|ral stri|
|00001de0| 6e 67 20 66 6f 72 20 74 | 68 65 20 6e 75 6d 62 65 |ng for t|he numbe|
|00001df0| 72 20 3c 69 6e 56 61 6c | 75 65 3e 2e 0d 09 09 76 |r <inVal|ue>....v|
|00001e00| 6f 69 64 09 09 09 09 09 | 09 53 65 74 52 6f 6d 61 |oid.....|.SetRoma|
|00001e10| 6e 56 61 6c 75 65 28 20 | 6c 6f 6e 67 20 69 6e 56 |nValue( |long inV|
|00001e20| 61 6c 75 65 20 29 3b 0d | 09 09 0d 09 09 2f 2f 09 |alue );.|.....//.|
|00001e30| 50 6f 73 74 3a 09 52 65 | 74 75 72 6e 73 20 74 68 |Post:.Re|turns th|
|00001e40| 65 20 63 68 61 72 61 63 | 74 65 72 20 70 6f 73 69 |e charac|ter posi|
|00001e50| 74 69 6f 6e 20 77 69 74 | 68 69 6e 20 74 68 69 73 |tion wit|hin this|
|00001e60| 20 73 74 72 69 6e 67 20 | 6f 66 20 74 68 65 20 72 | string |of the r|
|00001e70| 69 67 68 74 6d 6f 73 74 | 20 6f 63 63 75 72 61 6e |ightmost| occuran|
|00001e80| 63 65 20 6f 66 20 3c 63 | 3e 2e 20 49 66 0d 09 09 |ce of <c|>. If...|
|00001e90| 2f 2f 09 09 09 3c 63 3e | 20 69 73 20 6e 6f 74 20 |//...<c>| is not |
|00001ea0| 66 6f 75 6e 64 2c 20 30 | 20 69 73 20 72 65 74 75 |found, 0| is retu|
|00001eb0| 72 6e 65 64 2e 0d 09 09 | 69 6e 6c 69 6e 65 20 6c |rned....|inline l|
|00001ec0| 6f 6e 67 09 09 09 09 09 | 46 69 6e 64 4c 61 73 74 |ong.....|FindLast|
|00001ed0| 49 6e 73 74 61 6e 63 65 | 4f 66 28 20 63 68 61 72 |Instance|Of( char|
|00001ee0| 20 63 20 29 20 63 6f 6e | 73 74 09 09 09 09 09 09 | c ) con|st......|
|00001ef0| 7b 20 72 65 74 75 72 6e | 20 46 69 6e 64 50 72 65 |{ return| FindPre|
|00001f00| 76 49 6e 73 74 61 6e 63 | 65 4f 66 28 20 6d 53 74 |vInstanc|eOf( mSt|
|00001f10| 72 4c 65 6e 2c 20 63 20 | 29 3b 09 09 7d 0d 0d 09 |rLen, c |);..}...|
|00001f20| 09 2f 2f 09 50 6f 73 74 | 3a 09 52 65 74 75 72 6e |.//.Post|:.Return|
|00001f30| 73 20 74 68 65 20 63 68 | 61 72 61 63 74 65 72 20 |s the ch|aracter |
|00001f40| 70 6f 73 69 74 69 6f 6e | 20 77 69 74 68 69 6e 20 |position| within |
|00001f50| 74 68 69 73 20 73 74 72 | 69 6e 67 20 6f 66 20 74 |this str|ing of t|
|00001f60| 68 65 20 6c 65 66 74 6d | 6f 73 74 20 6f 63 63 75 |he leftm|ost occu|
|00001f70| 72 61 6e 63 65 20 6f 66 | 20 3c 63 3e 20 61 66 74 |rance of| <c> aft|
|00001f80| 65 72 20 70 6f 73 20 3c | 69 6e 50 6f 73 3e 2e 20 |er pos <|inPos>. |
|00001f90| 0d 09 09 2f 2f 09 09 09 | 49 66 20 3c 63 3e 20 69 |...//...|If <c> i|
|00001fa0| 73 20 6e 6f 74 20 66 6f | 75 6e 64 2c 20 30 20 69 |s not fo|und, 0 i|
|00001fb0| 73 20 72 65 74 75 72 6e | 65 64 2e 20 20 09 0d 09 |s return|ed. ...|
|00001fc0| 09 6c 6f 6e 67 09 09 09 | 09 09 09 46 69 6e 64 4e |.long...|...FindN|
|00001fd0| 65 78 74 49 6e 73 74 61 | 6e 63 65 4f 66 28 20 6c |extInsta|nceOf( l|
|00001fe0| 6f 6e 67 20 69 6e 50 6f | 73 2c 20 63 68 61 72 20 |ong inPo|s, char |
|00001ff0| 63 20 29 20 63 6f 6e 73 | 74 3b 0d 0d 09 09 2f 2f |c ) cons|t;....//|
|00002000| 09 50 6f 73 74 3a 09 52 | 65 74 75 72 6e 73 20 74 |.Post:.R|eturns t|
|00002010| 68 65 20 63 68 61 72 61 | 63 74 65 72 20 70 6f 73 |he chara|cter pos|
|00002020| 69 74 69 6f 6e 20 77 69 | 74 68 69 6e 20 74 68 69 |ition wi|thin thi|
|00002030| 73 20 73 74 72 69 6e 67 | 20 6f 66 20 74 68 65 20 |s string| of the |
|00002040| 72 69 67 68 74 6d 6f 73 | 74 20 6f 63 63 75 72 61 |rightmos|t occura|
|00002050| 6e 63 65 20 6f 66 20 3c | 63 3e 20 61 66 74 65 72 |nce of <|c> after|
|00002060| 20 70 6f 73 20 3c 69 6e | 50 6f 73 3e 2e 20 0d 09 | pos <in|Pos>. ..|
|00002070| 09 2f 2f 09 09 09 49 66 | 20 3c 63 3e 20 69 73 20 |.//...If| <c> is |
|00002080| 6e 6f 74 20 66 6f 75 6e | 64 2c 20 30 20 69 73 20 |not foun|d, 0 is |
|00002090| 72 65 74 75 72 6e 65 64 | 2e 20 20 09 0d 09 09 6c |returned|. ....l|
|000020a0| 6f 6e 67 09 09 09 09 09 | 09 46 69 6e 64 50 72 65 |ong.....|.FindPre|
|000020b0| 76 49 6e 73 74 61 6e 63 | 65 4f 66 28 20 6c 6f 6e |vInstanc|eOf( lon|
|000020c0| 67 20 69 6e 50 6f 73 2c | 20 63 68 61 72 20 63 20 |g inPos,| char c |
|000020d0| 29 20 63 6f 6e 73 74 3b | 0d 09 09 0d 09 09 2f 2f |) const;|......//|
|000020e0| 09 50 6f 73 74 3a 09 43 | 6f 6d 70 61 72 65 73 20 |.Post:.C|ompares |
|000020f0| 74 68 69 73 20 73 74 72 | 20 77 69 74 68 20 3c 69 |this str| with <i|
|00002100| 6e 53 74 72 3e 20 61 6e | 64 20 72 65 74 75 72 6e |nStr> an|d return|
|00002110| 73 3a 0d 09 09 2f 2f 09 | 09 09 22 68 69 22 2e 63 |s:...//.|.."hi".c|
|00002120| 6f 6d 70 61 72 65 54 6f | 28 20 22 68 69 22 2c 20 |ompareTo|( "hi", |
|00002130| 33 2c 20 74 72 75 65 20 | 29 20 3d 3d 20 30 0d 09 |3, true |) == 0..|
|00002140| 09 2f 2f 09 09 09 22 61 | 22 2e 63 6f 6d 70 61 72 |.//..."a|".compar|
|00002150| 65 54 6f 28 20 22 7a 22 | 2c 20 32 2c 20 74 72 75 |eTo( "z"|, 2, tru|
|00002160| 65 20 29 20 3c 20 30 0d | 09 09 2f 2f 09 09 09 22 |e ) < 0.|..//..."|
|00002170| 5a 22 2e 63 6f 6d 70 61 | 72 65 54 6f 28 20 22 61 |Z".compa|reTo( "a|
|00002180| 22 2c 20 32 2c 20 66 61 | 6c 73 65 20 29 20 3e 20 |", 2, fa|lse ) > |
|00002190| 30 0d 09 09 69 6e 74 09 | 09 09 09 09 09 09 63 6f |0...int.|......co|
|000021a0| 6d 70 61 72 65 54 6f 28 | 20 63 6f 6e 73 74 20 55 |mpareTo(| const U|
|000021b0| 74 69 6c 53 74 72 2a 20 | 69 6e 53 74 72 2c 09 09 |tilStr* |inStr,..|
|000021c0| 09 62 6f 6f 6c 20 69 6e | 43 61 73 65 53 65 6e 73 |.bool in|CaseSens|
|000021d0| 69 74 69 76 65 20 3d 20 | 74 72 75 65 20 29 20 63 |itive = |true ) c|
|000021e0| 6f 6e 73 74 3b 0d 09 09 | 69 6e 74 09 09 09 09 09 |onst;...|int.....|
|000021f0| 09 09 63 6f 6d 70 61 72 | 65 54 6f 28 20 63 6f 6e |..compar|eTo( con|
|00002200| 73 74 20 75 6e 73 69 67 | 6e 65 64 20 63 68 61 72 |st unsig|ned char|
|00002210| 2a 20 69 6e 50 53 74 72 | 2c 20 09 62 6f 6f 6c 20 |* inPStr|, .bool |
|00002220| 69 6e 43 61 73 65 53 65 | 6e 73 69 74 69 76 65 20 |inCaseSe|nsitive |
|00002230| 3d 20 74 72 75 65 20 29 | 20 63 6f 6e 73 74 3b 0d |= true )| const;.|
|00002240| 09 09 69 6e 74 09 09 09 | 09 09 09 09 63 6f 6d 70 |..int...|....comp|
|00002250| 61 72 65 54 6f 28 20 63 | 6f 6e 73 74 20 63 68 61 |areTo( c|onst cha|
|00002260| 72 2a 20 69 6e 43 53 74 | 72 2c 20 09 09 09 09 62 |r* inCSt|r, ....b|
|00002270| 6f 6f 6c 20 69 6e 43 61 | 73 65 53 65 6e 73 69 74 |ool inCa|seSensit|
|00002280| 69 76 65 20 3d 20 74 72 | 75 65 20 29 20 63 6f 6e |ive = tr|ue ) con|
|00002290| 73 74 3b 0d 0d 0d 09 09 | 2f 2f 09 50 6f 73 74 3a |st;.....|//.Post:|
|000022a0| 09 43 6f 6d 70 61 72 65 | 73 20 74 68 65 20 66 69 |.Compare|s the fi|
|000022b0| 72 73 74 20 3c 69 6e 4e | 3e 20 63 68 61 72 73 20 |rst <inN|> chars |
|000022c0| 6f 66 20 64 61 74 61 20 | 61 74 20 3c 73 31 3e 20 |of data |at <s1> |
|000022d0| 61 6e 64 20 3c 73 32 3e | 20 61 6e 64 20 72 65 74 |and <s2>| and ret|
|000022e0| 75 72 6e 73 3a 0d 09 09 | 2f 2f 09 09 09 53 74 72 |urns:...|//...Str|
|000022f0| 43 6d 70 28 20 22 68 69 | 22 2c 20 22 68 69 22 2c |Cmp( "hi|", "hi",|
|00002300| 20 33 2c 20 74 72 75 65 | 20 29 20 3d 3d 20 30 0d | 3, true| ) == 0.|
|00002310| 09 09 2f 2f 09 09 09 53 | 74 72 43 6d 70 28 20 22 |..//...S|trCmp( "|
|00002320| 61 22 2c 20 22 7a 22 2c | 20 32 2c 20 74 72 75 65 |a", "z",| 2, true|
|00002330| 20 29 20 3c 20 30 0d 09 | 09 2f 2f 09 09 09 53 74 | ) < 0..|.//...St|
|00002340| 72 43 6d 70 28 20 22 7a | 22 2c 20 22 61 22 2c 20 |rCmp( "z|", "a", |
|00002350| 32 2c 20 74 72 75 65 20 | 29 20 3e 20 30 0d 09 09 |2, true |) > 0...|
|00002360| 2f 2f 09 4e 6f 74 65 3a | 09 49 66 20 3c 69 6e 4e |//.Note:|.If <inN|
|00002370| 3e 20 3c 20 30 2c 20 74 | 68 65 20 6c 65 6e 67 74 |> < 0, t|he lengt|
|00002380| 68 20 6f 66 20 73 31 20 | 28 61 73 20 61 20 43 20 |h of s1 |(as a C |
|00002390| 73 74 72 69 6e 67 29 20 | 69 73 20 75 73 65 64 2e |string) |is used.|
|000023a0| 0d 09 09 2f 2f 09 4e 6f | 74 65 3a 09 53 74 72 43 |...//.No|te:.StrC|
|000023b0| 6d 70 28 20 2a 2c 20 2a | 2c 20 30 2c 20 2a 20 29 |mp( *, *|, 0, * )|
|000023c0| 20 61 6c 77 61 79 73 20 | 72 65 74 75 72 6e 73 20 | always |returns |
|000023d0| 66 61 6c 73 65 2e 0d 09 | 09 73 74 61 74 69 63 20 |false...|.static |
|000023e0| 69 6e 74 09 09 09 09 09 | 53 74 72 43 6d 70 28 20 |int.....|StrCmp( |
|000023f0| 63 6f 6e 73 74 20 63 68 | 61 72 2a 20 73 31 2c 20 |const ch|ar* s1, |
|00002400| 63 6f 6e 73 74 20 63 68 | 61 72 2a 20 73 32 2c 20 |const ch|ar* s2, |
|00002410| 6c 6f 6e 67 20 69 6e 4e | 2c 20 62 6f 6f 6c 20 69 |long inN|, bool i|
|00002420| 6e 43 61 73 65 53 65 6e | 73 69 74 69 76 65 20 29 |nCaseSen|sitive )|
|00002430| 3b 0d 09 09 09 09 0d 09 | 09 2f 2f 09 50 6f 73 74 |;.......|.//.Post|
|00002440| 3a 09 52 65 74 75 72 6e | 73 20 74 68 65 20 31 73 |:.Return|s the 1s|
|00002450| 74 20 6e 65 78 74 20 69 | 6e 73 74 61 6e 63 65 20 |t next i|nstance |
|00002460| 6f 66 20 3c 69 6e 53 74 | 72 3e 20 69 6e 20 74 68 |of <inSt|r> in th|
|00002470| 69 73 20 73 74 72 2c 20 | 73 6b 69 70 70 69 6e 67 |is str, |skipping|
|00002480| 20 74 68 65 20 66 69 72 | 73 74 20 69 6e 53 74 61 | the fir|st inSta|
|00002490| 72 74 69 6e 67 50 6f 73 | 20 63 68 61 72 73 2e 20 |rtingPos| chars. |
|000024a0| 20 20 49 66 20 61 6e 20 | 69 6e 73 74 61 6e 63 65 | If an |instance|
|000024b0| 20 63 61 6e 6e 6f 74 20 | 62 65 20 66 6f 75 6e 64 | cannot |be found|
|000024c0| 2c 20 30 20 69 73 20 72 | 65 74 75 72 6e 65 64 2e |, 0 is r|eturned.|
|000024d0| 0d 09 09 2f 2f 09 4e 6f | 74 65 3a 09 69 6e 4c 65 |...//.No|te:.inLe|
|000024e0| 6e 20 69 73 20 74 68 65 | 20 6c 65 6e 67 74 68 20 |n is the| length |
|000024f0| 6f 66 20 69 6e 53 74 72 | 2e 20 20 49 66 20 69 6e |of inStr|. If in|
|00002500| 4c 65 6e 20 3c 20 2d 31 | 2c 20 74 68 65 20 6c 65 |Len < -1|, the le|
|00002510| 6e 67 74 68 20 6f 66 20 | 69 6e 53 74 72 20 69 73 |ngth of |inStr is|
|00002520| 20 63 61 6c 63 75 6c 61 | 74 65 64 0d 09 09 2f 2f | calcula|ted...//|
|00002530| 09 09 09 22 48 69 2c 46 | 72 65 64 22 2e 63 6f 6e |..."Hi,F|red".con|
|00002540| 74 61 69 6e 73 28 20 22 | 66 72 65 64 22 2c 20 66 |tains( "|fred", f|
|00002550| 61 6c 73 65 20 29 20 3d | 3d 20 34 0d 09 09 69 6e |alse ) =|= 4...in|
|00002560| 6c 69 6e 65 20 6c 6f 6e | 67 20 09 09 09 09 63 6f |line lon|g ....co|
|00002570| 6e 74 61 69 6e 73 28 20 | 63 6f 6e 73 74 20 55 74 |ntains( |const Ut|
|00002580| 69 6c 53 74 72 26 09 69 | 6e 53 74 72 2c 09 09 09 |ilStr&.i|nStr,...|
|00002590| 09 09 69 6e 74 20 69 6e | 53 74 61 72 74 69 6e 67 |..int in|Starting|
|000025a0| 50 6f 73 20 3d 20 30 2c | 09 62 6f 6f 6c 20 69 6e |Pos = 0,|.bool in|
|000025b0| 43 61 73 65 53 65 6e 73 | 69 74 69 76 65 20 3d 20 |CaseSens|itive = |
|000025c0| 74 72 75 65 20 29 20 63 | 6f 6e 73 74 09 09 09 7b |true ) c|onst...{|
|000025d0| 20 72 65 74 75 72 6e 20 | 63 6f 6e 74 61 69 6e 73 | return |contains|
|000025e0| 28 20 69 6e 53 74 72 2e | 67 65 74 43 53 74 72 28 |( inStr.|getCStr(|
|000025f0| 29 2c 20 69 6e 53 74 72 | 2e 6c 65 6e 67 74 68 28 |), inStr|.length(|
|00002600| 29 2c 20 69 6e 53 74 61 | 72 74 69 6e 67 50 6f 73 |), inSta|rtingPos|
|00002610| 2c 20 69 6e 43 61 73 65 | 53 65 6e 73 69 74 69 76 |, inCase|Sensitiv|
|00002620| 65 20 29 3b 09 7d 09 09 | 0d 09 09 6c 6f 6e 67 20 |e );.}..|...long |
|00002630| 09 09 09 09 09 09 63 6f | 6e 74 61 69 6e 73 28 20 |......co|ntains( |
|00002640| 63 6f 6e 73 74 20 63 68 | 61 72 2a 09 09 69 6e 53 |const ch|ar*..inS|
|00002650| 74 72 2c 20 69 6e 74 20 | 69 6e 4c 65 6e 20 3d 20 |tr, int |inLen = |
|00002660| 2d 31 2c 09 69 6e 74 20 | 69 6e 53 74 61 72 74 69 |-1,.int |inStarti|
|00002670| 6e 67 50 6f 73 20 3d 20 | 30 2c 20 09 62 6f 6f 6c |ngPos = |0, .bool|
|00002680| 20 69 6e 43 61 73 65 53 | 65 6e 73 69 74 69 76 65 | inCaseS|ensitive|
|00002690| 20 3d 20 74 72 75 65 20 | 29 20 63 6f 6e 73 74 3b | = true |) const;|
|000026a0| 09 09 0d 09 09 0d 09 09 | 2f 2f 09 50 6f 73 74 3a |........|//.Post:|
|000026b0| 09 42 6c 6f 63 6b 6d 6f | 76 65 73 20 6d 65 6d 6f |.Blockmo|ves memo|
|000026c0| 72 79 0d 09 09 73 74 61 | 74 69 63 20 76 6f 69 64 |ry...sta|tic void|
|000026d0| 09 09 09 09 09 4d 6f 76 | 65 28 20 76 6f 69 64 2a |.....Mov|e( void*|
|000026e0| 20 69 6e 44 65 73 74 2c | 20 63 6f 6e 73 74 20 76 | inDest,| const v|
|000026f0| 6f 69 64 2a 20 69 6e 53 | 72 63 65 2c 20 75 6e 73 |oid* inS|rce, uns|
|00002700| 69 67 6e 65 64 20 6c 6f | 6e 67 20 69 6e 4e 75 6d |igned lo|ng inNum|
|00002710| 42 79 74 65 73 20 29 3b | 20 0d 0d 09 09 2f 2f 09 |Bytes );| ....//.|
|00002720| 50 6f 73 74 3a 09 41 70 | 70 65 6e 64 73 20 3c 69 |Post:.Ap|pends <i|
|00002730| 6e 53 74 72 3e 2c 20 65 | 78 70 6f 72 74 69 6e 67 |nStr>, e|xporting|
|00002740| 2f 74 72 61 6e 73 6c 61 | 74 69 6e 67 20 3c 69 6e |/transla|ting <in|
|00002750| 44 61 74 61 3e 20 74 6f | 20 22 6d 65 74 61 22 20 |Data> to| "meta" |
|00002760| 66 6f 72 6d 61 74 20 28 | 69 65 2c 20 61 6c 6c 20 |format (|ie, all |
|00002770| 74 72 61 6e 73 6c 61 74 | 65 64 20 62 79 74 65 73 |translat|ed bytes|
|00002780| 20 3e 3d 20 33 32 20 6f | 72 20 3c 3d 20 31 32 37 | >= 32 o|r <= 127|
|00002790| 29 0d 09 09 76 6f 69 64 | 09 09 09 09 09 09 41 70 |)...void|......Ap|
|000027a0| 70 65 6e 64 41 73 4d 65 | 74 61 28 20 63 6f 6e 73 |pendAsMe|ta( cons|
|000027b0| 74 20 55 74 69 6c 53 74 | 72 2a 20 69 6e 44 61 74 |t UtilSt|r* inDat|
|000027c0| 61 20 29 3b 0d 09 09 76 | 6f 69 64 09 09 09 09 09 |a );...v|oid.....|
|000027d0| 09 41 70 70 65 6e 64 41 | 73 4d 65 74 61 28 20 63 |.AppendA|sMeta( c|
|000027e0| 6f 6e 73 74 20 76 6f 69 | 64 2a 20 69 6e 44 61 74 |onst voi|d* inDat|
|000027f0| 61 2c 20 6c 6f 6e 67 20 | 69 6e 4c 65 6e 20 29 3b |a, long |inLen );|
|00002800| 0d 09 09 0d 09 09 2f 2f | 09 50 6f 73 74 3a 09 41 |......//|.Post:.A|
|00002810| 70 70 65 6e 64 73 20 3c | 69 6e 53 74 72 3e 2c 20 |ppends <|inStr>, |
|00002820| 69 6d 70 6f 72 74 69 6e | 67 2f 74 72 61 6e 73 6c |importin|g/transl|
|00002830| 61 74 69 6e 67 20 3c 69 | 6e 53 74 72 3e 20 66 72 |ating <i|nStr> fr|
|00002840| 6f 6d 20 22 6d 65 74 61 | 22 20 66 6f 72 6d 61 74 |om "meta|" format|
|00002850| 2e 0d 09 09 2f 2f 09 4e | 6f 74 65 3a 09 53 65 65 |....//.N|ote:.See|
|00002860| 20 41 70 70 65 6e 64 41 | 73 4d 65 74 61 28 29 0d | AppendA|sMeta().|
|00002870| 09 09 2f 2f 09 45 78 3a | 09 09 73 2e 57 69 70 65 |..//.Ex:|..s.Wipe|
|00002880| 28 29 3b 20 74 2e 57 69 | 70 65 28 29 3b 09 09 09 |(); t.Wi|pe();...|
|00002890| 09 09 09 09 09 2f 2f 20 | 45 6d 70 74 79 20 6f 75 |.....// |Empty ou|
|000028a0| 72 20 73 74 72 69 6e 67 | 73 20 73 20 61 6e 64 20 |r string|s s and |
|000028b0| 74 0d 09 09 2f 2f 09 09 | 09 73 2e 41 70 70 65 6e |t...//..|.s.Appen|
|000028c0| 64 41 73 4d 65 74 61 28 | 20 64 61 74 61 50 74 72 |dAsMeta(| dataPtr|
|000028d0| 2c 20 35 20 29 3b 20 09 | 09 09 09 09 2f 2f 20 45 |, 5 ); .|....// E|
|000028e0| 6e 63 6f 64 65 20 73 6f | 6d 65 20 64 61 74 61 20 |ncode so|me data |
|000028f0| 61 6e 64 20 70 75 74 20 | 69 74 20 69 6e 20 73 0d |and put |it in s.|
|00002900| 09 09 2f 2f 09 09 09 74 | 2e 41 70 70 65 6e 64 46 |..//...t|.AppendF|
|00002910| 72 6f 6d 4d 65 74 61 28 | 20 73 2e 67 65 74 43 53 |romMeta(| s.getCS|
|00002920| 74 72 28 29 2c 20 73 2e | 6c 65 6e 67 74 68 28 29 |tr(), s.|length()|
|00002930| 20 29 3b 09 2f 2f 20 74 | 20 6e 6f 77 20 63 6f 6e | );.// t| now con|
|00002940| 74 61 69 6e 73 20 65 78 | 61 63 74 6c 79 20 77 68 |tains ex|actly wh|
|00002950| 61 74 20 77 61 73 20 69 | 6e 20 64 61 74 61 50 74 |at was i|n dataPt|
|00002960| 72 09 09 09 09 0d 09 09 | 76 6f 69 64 09 09 09 09 |r.......|void....|
|00002970| 09 09 41 70 70 65 6e 64 | 46 72 6f 6d 4d 65 74 61 |..Append|FromMeta|
|00002980| 28 20 63 6f 6e 73 74 20 | 55 74 69 6c 53 74 72 2a |( const |UtilStr*|
|00002990| 20 69 6e 53 74 72 20 29 | 3b 0d 09 09 76 6f 69 64 | inStr )|;...void|
|000029a0| 09 09 09 09 09 09 41 70 | 70 65 6e 64 46 72 6f 6d |......Ap|pendFrom|
|000029b0| 4d 65 74 61 28 20 63 6f | 6e 73 74 20 76 6f 69 64 |Meta( co|nst void|
|000029c0| 2a 20 69 6e 53 74 72 2c | 20 6c 6f 6e 67 20 69 6e |* inStr,| long in|
|000029d0| 4c 65 6e 20 29 3b 0d 09 | 09 0d 09 09 2f 2f 20 50 |Len );..|....// P|
|000029e0| 6f 73 74 3a 09 52 65 74 | 75 72 6e 73 20 61 20 70 |ost:.Ret|urns a p|
|000029f0| 73 75 64 6f 72 61 6e 64 | 6f 6d 20 6c 6f 6e 67 20 |sudorand|om long |
|00002a00| 66 6f 72 20 74 68 69 73 | 20 73 74 72 69 6e 67 0d |for this| string.|
|00002a10| 09 09 6c 6f 6e 67 09 09 | 09 09 09 09 48 61 73 68 |..long..|....Hash|
|00002a20| 28 29 20 63 6f 6e 73 74 | 3b 0d 09 09 0d 09 09 2f |() const|;....../|
|00002a30| 2f 20 4d 75 73 74 20 62 | 65 20 64 65 66 69 6e 65 |/ Must b|e define|
|00002a40| 64 20 61 73 20 61 20 48 | 61 73 68 61 62 6c 65 0d |d as a H|ashable.|
|00002a50| 09 09 62 6f 6f 6c 09 09 | 09 09 09 09 45 71 75 61 |..bool..|....Equa|
|00002a60| 6c 73 28 20 63 6f 6e 73 | 74 20 48 61 73 68 61 62 |ls( cons|t Hashab|
|00002a70| 6c 65 2a 20 69 6e 43 6f | 6d 70 20 29 20 63 6f 6e |le* inCo|mp ) con|
|00002a80| 73 74 3b 0d 09 09 0d 09 | 09 0d 09 09 0d 09 09 2f |st;.....|......./|
|00002a90| 2f 20 50 72 65 3a 09 09 | 69 6e 42 31 20 61 6e 64 |/ Pre:..|inB1 and|
|00002aa0| 20 69 6e 42 32 20 61 72 | 65 20 27 30 27 20 74 6f | inB2 ar|e '0' to|
|00002ab0| 20 27 39 27 2c 20 27 41 | 27 20 74 6f 20 27 46 27 | '9', 'A|' to 'F'|
|00002ac0| 2c 20 6f 72 20 27 61 27 | 20 74 6f 20 27 66 27 0d |, or 'a'| to 'f'.|
|00002ad0| 09 09 2f 2f 20 50 6f 73 | 74 3a 09 54 68 65 20 63 |..// Pos|t:.The c|
|00002ae0| 6f 72 72 65 73 70 6f 6e | 64 69 6e 67 20 62 79 74 |orrespon|ding byt|
|00002af0| 65 20 76 61 6c 75 65 20 | 69 73 20 61 70 70 65 6e |e value |is appen|
|00002b00| 64 65 64 20 74 6f 20 74 | 68 69 73 20 73 74 72 69 |ded to t|his stri|
|00002b10| 6e 67 0d 09 09 76 6f 69 | 64 09 09 09 09 09 09 41 |ng...voi|d......A|
|00002b20| 70 70 65 6e 64 48 65 78 | 28 20 63 68 61 72 20 69 |ppendHex|( char i|
|00002b30| 6e 42 31 2c 20 63 68 61 | 72 20 69 6e 42 32 20 29 |nB1, cha|r inB2 )|
|00002b40| 3b 0d 0d 09 09 2f 2f 20 | 50 6f 73 74 3a 09 52 65 |;....// |Post:.Re|
|00002b50| 74 75 72 6e 73 20 61 20 | 66 6c 6f 61 74 69 6e 67 |turns a |floating|
|00002b60| 20 70 6f 69 6e 74 20 6e | 75 6d 62 65 72 20 66 6f | point n|umber fo|
|00002b70| 72 20 74 68 65 20 67 69 | 76 65 6e 20 41 53 43 49 |r the gi|ven ASCI|
|00002b80| 49 20 63 68 61 72 73 0d | 09 09 73 74 61 74 69 63 |I chars.|..static|
|00002b90| 20 64 6f 75 62 6c 65 09 | 09 09 09 47 65 74 46 6c | double.|...GetFl|
|00002ba0| 6f 61 74 56 61 6c 28 20 | 63 68 61 72 2a 20 69 6e |oatVal( |char* in|
|00002bb0| 4e 75 6d 53 74 72 2c 20 | 6c 6f 6e 67 20 69 6e 4c |NumStr, |long inL|
|00002bc0| 65 6e 20 29 3b 0d 09 09 | 0d 09 09 2f 2f 09 50 6f |en );...|...//.Po|
|00002bd0| 73 74 3a 09 52 65 74 75 | 72 6e 73 20 74 68 65 20 |st:.Retu|rns the |
|00002be0| 74 72 75 6e 63 61 74 65 | 64 20 73 69 67 6e 65 64 |truncate|d signed|
|00002bf0| 20 6c 6f 6e 67 20 76 61 | 6c 75 65 20 6f 66 20 74 | long va|lue of t|
|00002c00| 68 69 73 20 73 74 72 69 | 6e 67 2e 20 20 41 6c 6c |his stri|ng. All|
|00002c10| 20 63 68 61 72 61 63 74 | 65 72 73 20 6e 6f 74 20 | charact|ers not |
|00002c20| 27 30 27 2e 2e 27 39 27 | 20 61 72 65 20 69 67 6e |'0'..'9'| are ign|
|00002c30| 6f 72 65 64 0d 09 09 2f | 2f 09 09 09 65 78 63 65 |ored.../|/...exce|
|00002c40| 70 74 20 61 20 6c 65 61 | 64 69 6e 67 20 27 2d 27 |pt a lea|ding '-'|
|00002c50| 0d 09 09 2f 2f 09 09 09 | 3c 2a 6f 75 74 50 6c 61 |...//...|<*outPla|
|00002c60| 63 65 50 74 72 3e 20 69 | 73 20 73 65 74 20 74 6f |cePtr> i|s set to|
|00002c70| 20 31 30 5e 28 20 31 20 | 2b 20 74 72 75 6e 63 28 | 10^( 1 |+ trunc(|
|00002c80| 20 6c 6f 67 31 30 28 20 | 3c 73 74 72 56 61 6c 3e | log10( |<strVal>|
|00002c90| 20 29 20 29 20 29 0d 09 | 09 2f 2f 09 55 73 61 67 | ) ) )..|.//.Usag|
|00002ca0| 65 3a 09 22 31 32 2e 39 | 22 2e 47 65 74 49 6e 74 |e:."12.9|".GetInt|
|00002cb0| 56 61 6c 75 65 28 20 26 | 69 20 29 20 72 65 74 75 |Value( &|i ) retu|
|00002cc0| 72 6e 73 20 31 32 20 61 | 6e 64 20 61 73 73 69 67 |rns 12 a|nd assig|
|00002cd0| 6e 73 20 69 20 74 6f 20 | 31 30 30 0d 09 09 73 74 |ns i to |100...st|
|00002ce0| 61 74 69 63 20 6c 6f 6e | 67 09 09 09 09 09 47 65 |atic lon|g.....Ge|
|00002cf0| 74 49 6e 74 56 61 6c 75 | 65 28 20 63 68 61 72 2a |tIntValu|e( char*|
|00002d00| 20 69 6e 53 74 72 2c 20 | 6c 6f 6e 67 20 69 6e 4c | inStr, |long inL|
|00002d10| 65 6e 2c 20 6c 6f 6e 67 | 2a 20 6f 75 74 50 6c 61 |en, long|* outPla|
|00002d20| 63 65 50 74 72 20 3d 20 | 4e 55 4c 4c 20 29 3b 0d |cePtr = |NULL );.|
|00002d30| 0d 09 70 72 6f 74 65 63 | 74 65 64 3a 0d 09 09 75 |..protec|ted:...u|
|00002d40| 6e 73 69 67 6e 65 64 20 | 6c 6f 6e 67 09 09 09 09 |nsigned |long....|
|00002d50| 6d 42 75 66 53 69 7a 65 | 3b 20 09 09 09 09 2f 2f |mBufSize|; ....//|
|00002d60| 20 50 68 79 73 69 63 61 | 6c 20 73 69 7a 65 20 6f | Physica|l size o|
|00002d70| 66 20 62 75 66 0d 09 09 | 75 6e 73 69 67 6e 65 64 |f buf...|unsigned|
|00002d80| 20 6c 6f 6e 67 09 09 09 | 09 6d 53 74 72 4c 65 6e | long...|.mStrLen|
|00002d90| 3b 09 09 09 09 2f 2f 20 | 4e 4f 54 45 3a 20 41 4c |;....// |NOTE: AL|
|00002da0| 57 41 59 53 20 68 6f 6c | 64 73 20 73 74 72 69 6e |WAYS hol|ds strin|
|00002db0| 67 20 73 69 7a 65 0d 09 | 09 63 68 61 72 2a 09 09 |g size..|.char*..|
|00002dc0| 09 09 09 09 6d 42 75 66 | 3b 09 09 09 09 09 2f 2f |....mBuf|;.....//|
|00002dd0| 20 48 6f 6c 64 73 20 70 | 74 72 20 74 6f 20 73 74 | Holds p|tr to st|
|00002de0| 72 20 64 61 74 61 0d 09 | 09 0d 09 09 76 6f 69 64 |r data..|....void|
|00002df0| 09 09 09 09 09 09 69 6e | 69 74 28 29 3b 0d 0d 09 |......in|it();...|
|00002e00| 09 66 72 69 65 6e 64 20 | 63 6c 61 73 73 20 55 74 |.friend |class Ut|
|00002e10| 69 6c 53 74 72 3b 0d 7d | 3b 0d 0d 0d 0d 0d 23 65 |ilStr;.}|;.....#e|
|00002e20| 6e 64 69 66 0d 00 00 00 | 00 00 00 00 00 00 00 00 |ndif....|........|
|00002e30| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00002e40| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00002e50| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00002e60| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00002e70| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00002e80| 00 00 01 00 00 00 01 54 | 00 00 00 54 00 00 00 46 |.......T|...T...F|
|00002e90| 2a 2a 2a 2a 2a 2a 2a 2a | 2a 2a 2a 2a 2a 2a 2a 2a |********|********|
|00002ea0| 2a 2a 2a 2a 2a 2a 2a 2a | 2a 2a 2a 2a 2a 2a 2a 2a |********|********|
|00002eb0| 0a 43 55 74 69 6c 53 74 | 72 2e 68 33 20 44 65 76 |.CUtilSt|r.h3 Dev|
|00002ec0| 37 36 34 32 70 33 2e 6d | 70 33 77 6f 72 6c 64 2e |7642p3.m|p3world.|
|00002ed0| 02 00 54 45 58 54 43 57 | 49 45 01 00 ff ff ff ff |..TEXTCW|IE......|
|00002ee0| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00002ef0| 00 00 ac 36 43 c8 00 00 | 2d 09 00 00 01 9a 72 65 |...6C...|-.....re|
|00002f00| 61 74 6f 72 2c 0d 09 09 | 09 09 09 09 09 09 09 20 |ator,...|....... |
|00002f10| 4f 53 54 79 70 65 20 66 | 69 6c 65 54 79 70 65 29 |OSType f|ileType)|
|00002f20| 3b 0d 2f 2a 09 a6 20 43 | 68 61 6e 67 65 20 74 68 |;./*.. C|hange th|
|00002f30| 65 20 63 72 65 61 74 6f | 72 20 6f 72 20 66 69 6c |e creato|r or fil|
|00002f40| 65 20 74 79 70 65 20 6f | 66 20 61 20 66 69 6c 65 |e type o|f a file|
|00002f50| 2e 0d 09 54 68 65 20 46 | 53 70 43 68 61 6e 67 65 |...The F|SpChange|
|00002f60| 43 72 65 61 74 6f 72 54 | 79 70 65 20 66 75 6e 63 |CreatorT|ype func|
|00002f70| 74 69 6f 6e 20 63 68 61 | 6e 67 65 73 20 74 68 65 |tion cha|nges the|
|00002f80| 00 00 00 48 00 09 4d 6f | 6e 61 63 6f 00 00 00 00 |...H..Mo|naco....|
|00002f90| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00002fa0| 00 00 00 00 00 00 00 03 | 00 04 00 5e 01 24 02 49 |........|...^.$.I|
|00002fb0| 03 13 00 5e 01 24 02 49 | 03 13 b3 b1 57 e3 00 00 |...^.$.I|....W...|
|00002fc0| 25 29 00 00 25 29 00 00 | 08 d9 01 00 00 00 00 04 |%)..%)..|........|
|00002fd0| 00 01 00 01 00 00 01 00 | 00 00 01 54 00 00 00 54 |........|...T...T|
|00002fe0| 00 00 00 46 05 6a fb a0 | 18 9c 00 00 00 1c 00 46 |...F.j..|.......F|
|00002ff0| 00 01 4d 50 53 52 00 00 | 00 12 4d 57 42 42 00 00 |..MPSR..|..MWBB..|
|00003000| 00 1e 03 ed ff ff 00 00 | 00 00 00 00 00 00 03 f0 |........|........|
|00003010| ff ff 00 00 00 4c 00 00 | 00 00 00 00 00 00 00 00 |.....L..|........|
|00003020| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00003030| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00003040| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00003050| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00003060| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
|00003070| 00 00 00 00 00 00 00 00 | 00 00 00 00 00 00 00 00 |........|........|
+--------+-------------------------+-------------------------+--------+--------+